class A:
    def __init__(self, txt: str):
        self.x: C = None
        self.y: E = None
        self.s: B = None
        self.o: F = None
        self.q: F = None
        self.t: D = None
        self.w: B = None
        self.u: C = None
        self.txt = txt

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

class C:
    def __init__(self, txt: str):
        self.o: A = None
        self.u: A = None
        self.s: G = None
        self.txt = txt

class D:
    def __init__(self, txt: str):
        self.y: H = None
        self.v: G = None
        self.z: C = None
        self.x: I = None
        self.q: A = None
        self.t: G = None
        self.p: I = None
        self.txt = txt

class E:
    def __init__(self, txt: str):
        self.z: A = None
        self.txt = txt

class F:
    def __init__(self, txt: str):
        self.w: C = None
        self.txt = txt

class G:
    def __init__(self, txt: str):
        self.u: H = None
        self.t: B = None
        self.x: F = None
        self.v: B = None
        self.o: E = None
        self.txt = txt

class H:
    def __init__(self, txt: str):
        self.u: G = None
        self.v: G = None
        self.r: G = None
        self.y: I = None
        self.t: E = None
        self.txt = txt

class I:
    def __init__(self, txt: str):
        self.q: H = None
        self.s: D = None
        self.z: E = None
        self.o: G = None
        self.u: H = None
        self.w: H = None
        self.v: B = None
        self.y: D = None
        self.txt = txt

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

a.x = m
a.u = m
a.y = d
a.s = k
a.w = k
a.o = c
a.q = c
a.t = i
k.y = e
k.v = a
k.x = i
m.o = a
m.u = a
m.s = e
i.y = g
i.v = e
i.t = e
i.z = m
i.x = j
i.p = j
i.q = a
d.z = a
c.w = m
e.u = g
e.t = k
e.v = k
e.x = c
e.o = d
g.u = e
g.v = e
g.r = e
g.y = j
g.t = d
j.q = g
j.u = g
j.w = g
j.s = i
j.y = i
j.z = d
j.o = e
j.v = k
assert a.t.z.s.o.z.s.txt == "
class A:
    def __init__(self, txt: str):
        self.x: C = None
        self.y: E = None
        self.s: B = None
        self.o: F = None
        self.q: F = None
        self.t: D = None
        self.w: B = None
        self.u: C = None
        self.txt = txt

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

class C:
    def __init__(self, txt: str):
        self.o: A = None
        self.u: A = None
        self.s: G = None
        self.txt = txt

class D:
    def __init__(self, txt: str):
        self.y: H = None
        self.v: G = None
        self.z: C = None
        self.x: I = None
        self.q: A = None
        self.t: G = None
        self.p: I = None
        self.txt = txt

class E:
    def __init__(self, txt: str):
        self.z: A = None
        self.txt = txt

class F:
    def __init__(self, txt: str):
        self.w: C = None
        self.txt = txt

class G:
    def __init__(self, txt: str):
        self.u: H = None
        self.t: B = None
        self.x: F = None
        self.v: B = None
        self.o: E = None
        self.txt = txt

class H:
    def __init__(self, txt: str):
        self.u: G = None
        self.v: G = None
        self.r: G = None
        self.y: I = None
        self.t: E = None
        self.txt = txt

class I:
    def __init__(self, txt: str):
        self.q: H = None
        self.s: D = None
        self.z: E = None
        self.o: G = None
        self.u: H = None
        self.w: H = None
        self.v: B = None
        self.y: D = None
        self.txt = txt

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

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