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

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

class C:
    def __init__(self, txt: str):
        self.p: G = None
        self.w: B = None
        self.v: E = None
        self.t: D = None
        self.o: I = None
        self.r: E = None
        self.txt = txt

class D:
    def __init__(self, txt: str):
        self.w: H = None
        self.t: E = None
        self.txt = txt

class E:
    def __init__(self, txt: str):
        self.v: F = None
        self.s: J = None
        self.t: C = None
        self.o: D = None
        self.w: H = None
        self.z: J = None
        self.r: F = None
        self.txt = txt

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

class G:
    def __init__(self, txt: str):
        self.w: H = None
        self.z: C = None
        self.o: A = None
        self.txt = txt

class H:
    def __init__(self, txt: str):
        self.z: D = None
        self.r: C = None
        self.w: J = None
        self.txt = txt

class I:
    def __init__(self, txt: str):
        self.q: C = None
        self.t: G = None
        self.w: A = None
        self.u: C = None
        self.o: D = None
        self.txt = txt

class J:
    def __init__(self, txt: str):
        self.s: G = None
        self.v: D = None
        self.p: D = None
        self.z: H = None
        self.txt = txt

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

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

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

class C:
    def __init__(self, txt: str):
        self.p: G = None
        self.w: B = None
        self.v: E = None
        self.t: D = None
        self.o: I = None
        self.r: E = None
        self.txt = txt

class D:
    def __init__(self, txt: str):
        self.w: H = None
        self.t: E = None
        self.txt = txt

class E:
    def __init__(self, txt: str):
        self.v: F = None
        self.s: J = None
        self.t: C = None
        self.o: D = None
        self.w: H = None
        self.z: J = None
        self.r: F = None
        self.txt = txt

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

class G:
    def __init__(self, txt: str):
        self.w: H = None
        self.z: C = None
        self.o: A = None
        self.txt = txt

class H:
    def __init__(self, txt: str):
        self.z: D = None
        self.r: C = None
        self.w: J = None
        self.txt = txt

class I:
    def __init__(self, txt: str):
        self.q: C = None
        self.t: G = None
        self.w: A = None
        self.u: C = None
        self.o: D = None
        self.txt = txt

class J:
    def __init__(self, txt: str):
        self.s: G = None
        self.v: D = None
        self.p: D = None
        self.z: H = None
        self.txt = txt

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

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