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

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

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

class D:
    def __init__(self, txt: str):
        self.v: J = None
        self.txt = txt

class E:
    def __init__(self, txt: str):
        self.x: B = None
        self.txt = txt

class F:
    def __init__(self, txt: str):
        self.z: J = None
        self.x: I = None
        self.t: E = None
        self.q: J = None
        self.txt = txt

class G:
    def __init__(self, txt: str):
        self.w: E = None
        self.r: I = None
        self.o: F = None
        self.x: H = None
        self.s: H = None
        self.y: B = None
        self.v: F = None
        self.txt = txt

class H:
    def __init__(self, txt: str):
        self.u: B = None
        self.txt = txt

class I:
    def __init__(self, txt: str):
        self.q: A = None
        self.t: G = None
        self.r: H = None
        self.z: E = None
        self.p: F = None
        self.txt = txt

class J:
    def __init__(self, txt: str):
        self.z: I = None
        self.r: D = None
        self.u: F = None
        self.w: I = None
        self.x: I = None
        self.p: H = None
        self.s: F = None
        self.txt = txt

b = A("b")
a = B("a")
d = C("d")
j = D("j")
k = E("k")
m = F("m")
f = G("f")
e = H("e")
i = I("i")
l = J("l")

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

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

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

class D:
    def __init__(self, txt: str):
        self.v: J = None
        self.txt = txt

class E:
    def __init__(self, txt: str):
        self.x: B = None
        self.txt = txt

class F:
    def __init__(self, txt: str):
        self.z: J = None
        self.x: I = None
        self.t: E = None
        self.q: J = None
        self.txt = txt

class G:
    def __init__(self, txt: str):
        self.w: E = None
        self.r: I = None
        self.o: F = None
        self.x: H = None
        self.s: H = None
        self.y: B = None
        self.v: F = None
        self.txt = txt

class H:
    def __init__(self, txt: str):
        self.u: B = None
        self.txt = txt

class I:
    def __init__(self, txt: str):
        self.q: A = None
        self.t: G = None
        self.r: H = None
        self.z: E = None
        self.p: F = None
        self.txt = txt

class J:
    def __init__(self, txt: str):
        self.z: I = None
        self.r: D = None
        self.u: F = None
        self.w: I = None
        self.x: I = None
        self.p: H = None
        self.s: F = None
        self.txt = txt

b = A("b")
a = B("a")
d = C("d")
j = D("j")
k = E("k")
m = F("m")
f = G("f")
e = H("e")
i = I("i")
l = J("l")

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