class A:
    def __init__(self, txt: str):
        self.v: B = None
        self.txt = txt

class B:
    def __init__(self, txt: str):
        self.z: C = None
        self.u: F = None
        self.txt = txt

class C:
    def __init__(self, txt: str):
        self.x: A = None
        self.o: E = None
        self.u: A = None
        self.r: B = None
        self.p: I = None
        self.txt = txt

class D:
    def __init__(self, txt: str):
        self.o: C = None
        self.y: F = None
        self.txt = txt

class E:
    def __init__(self, txt: str):
        self.t: A = None
        self.o: G = None
        self.y: F = None
        self.r: D = None
        self.u: F = None
        self.txt = txt

class F:
    def __init__(self, txt: str):
        self.q: B = None
        self.x: C = None
        self.r: G = None
        self.u: D = None
        self.txt = txt

class G:
    def __init__(self, txt: str):
        self.o: B = None
        self.txt = txt

class H:
    def __init__(self, txt: str):
        self.p: G = None
        self.u: A = None
        self.txt = txt

class I:
    def __init__(self, txt: str):
        self.v: E = None
        self.x: H = None
        self.r: D = None
        self.y: E = None
        self.t: A = None
        self.o: E = None
        self.z: B = None
        self.s: H = None
        self.q: E = None
        self.txt = txt

d = A("d")
n = B("n")
e = C("e")
m = D("m")
c = E("c")
k = F("k")
b = G("b")
a = H("a")
j = I("j")

d.v = n
n.z = e
n.u = k
e.x = d
e.u = d
e.o = c
e.r = n
e.p = j
m.o = e
m.y = k
c.t = d
c.o = b
c.y = k
c.u = k
c.r = m
k.q = n
k.x = e
k.r = b
k.u = m
b.o = n
a.p = b
a.u = d
j.v = c
j.y = c
j.o = c
j.q = c
j.x = a
j.s = a
j.r = m
j.t = d
j.z = n
assert a.u.v.u.r.o.u.q.u.txt == "
class A:
    def __init__(self, txt: str):
        self.v: B = None
        self.txt = txt

class B:
    def __init__(self, txt: str):
        self.z: C = None
        self.u: F = None
        self.txt = txt

class C:
    def __init__(self, txt: str):
        self.x: A = None
        self.o: E = None
        self.u: A = None
        self.r: B = None
        self.p: I = None
        self.txt = txt

class D:
    def __init__(self, txt: str):
        self.o: C = None
        self.y: F = None
        self.txt = txt

class E:
    def __init__(self, txt: str):
        self.t: A = None
        self.o: G = None
        self.y: F = None
        self.r: D = None
        self.u: F = None
        self.txt = txt

class F:
    def __init__(self, txt: str):
        self.q: B = None
        self.x: C = None
        self.r: G = None
        self.u: D = None
        self.txt = txt

class G:
    def __init__(self, txt: str):
        self.o: B = None
        self.txt = txt

class H:
    def __init__(self, txt: str):
        self.p: G = None
        self.u: A = None
        self.txt = txt

class I:
    def __init__(self, txt: str):
        self.v: E = None
        self.x: H = None
        self.r: D = None
        self.y: E = None
        self.t: A = None
        self.o: E = None
        self.z: B = None
        self.s: H = None
        self.q: E = None
        self.txt = txt

d = A("d")
n = B("n")
e = C("e")
m = D("m")
c = E("c")
k = F("k")
b = G("b")
a = H("a")
j = I("j")

d.v = n
n.z = e
n.u = k
e.x = d
e.u = d
e.o = c
e.r = n
e.p = j
m.o = e
m.y = k
c.t = d
c.o = b
c.y = k
c.u = k
c.r = m
k.q = n
k.x = e
k.r = b
k.u = m
b.o = n
a.p = b
a.u = d
j.v = c
j.y = c
j.o = c
j.q = c
j.x = a
j.s = a
j.r = m
j.t = d
j.z = n
assert a.u.v.u.r.o.u.q.u.txt == "k"