class A:
    def __init__(self, txt: str):
        self.t: F = None
        self.txt = txt

class B:
    def __init__(self, txt: str):
        self.r: F = None
        self.t: E = None
        self.txt = txt

class C:
    def __init__(self, txt: str):
        self.u: H = None
        self.r: G = None
        self.s: D = None
        self.p: H = None
        self.t: I = None
        self.txt = txt

class D:
    def __init__(self, txt: str):
        self.r: F = None
        self.z: A = None
        self.txt = txt

class E:
    def __init__(self, txt: str):
        self.q: D = None
        self.txt = txt

class F:
    def __init__(self, txt: str):
        self.y: B = None
        self.w: E = None
        self.z: E = None
        self.txt = txt

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

class H:
    def __init__(self, txt: str):
        self.y: I = None
        self.x: D = None
        self.o: A = None
        self.txt = txt

class I:
    def __init__(self, txt: str):
        self.z: H = None
        self.txt = txt

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

i.t = c
l.r = k
l.t = b
a.u = g
a.p = g
a.r = j
a.s = d
a.t = n
d.r = k
d.z = i
b.q = d
c.y = l
c.w = b
c.z = b
j.q = a
j.u = a
j.p = c
j.z = c
j.r = n
j.x = n
g.y = n
g.x = d
g.o = i
n.z = g
k.y = l
k.w = b
k.z = b
assert l.t.q.z.t.txt == "
class A:
    def __init__(self, txt: str):
        self.t: F = None
        self.txt = txt

class B:
    def __init__(self, txt: str):
        self.r: F = None
        self.t: E = None
        self.txt = txt

class C:
    def __init__(self, txt: str):
        self.u: H = None
        self.r: G = None
        self.s: D = None
        self.p: H = None
        self.t: I = None
        self.txt = txt

class D:
    def __init__(self, txt: str):
        self.r: F = None
        self.z: A = None
        self.txt = txt

class E:
    def __init__(self, txt: str):
        self.q: D = None
        self.txt = txt

class F:
    def __init__(self, txt: str):
        self.y: B = None
        self.w: E = None
        self.z: E = None
        self.txt = txt

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

class H:
    def __init__(self, txt: str):
        self.y: I = None
        self.x: D = None
        self.o: A = None
        self.txt = txt

class I:
    def __init__(self, txt: str):
        self.z: H = None
        self.txt = txt

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

i.t = c
l.r = k
l.t = b
a.u = g
a.p = g
a.r = j
a.s = d
a.t = n
d.r = k
d.z = i
b.q = d
c.y = l
c.w = b
c.z = b
j.q = a
j.u = a
j.p = c
j.z = c
j.r = n
j.x = n
g.y = n
g.x = d
g.o = i
n.z = g
k.y = l
k.w = b
k.z = b
assert l.t.q.z.t.txt == "c"