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

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

class C:
    def __init__(self, txt: str):
        self.z: E = None
        self.q: A = None
        self.x: C = None
        self.o: B = None
        self.u: A = None
        self.s: C = None
        self.txt = txt

class D:
    def __init__(self, txt: str):
        self.r: E = None
        self.y: B = None
        self.o: B = None
        self.z: G = None
        self.q: B = None
        self.txt = txt

class E:
    def __init__(self, txt: str):
        self.s: D = None
        self.q: F = None
        self.u: G = None
        self.z: G = None
        self.x: G = None
        self.o: D = None
        self.txt = txt

class F:
    def __init__(self, txt: str):
        self.r: C = None
        self.x: C = None
        self.v: C = None
        self.p: E = None
        self.s: E = None
        self.o: C = None
        self.txt = txt

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

e = A("e")
a = B("a")
b = C("b")
m = D("m")
g = E("g")
d = F("d")
l = G("l")
n = C("n")
h = E("h")

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

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

class C:
    def __init__(self, txt: str):
        self.z: E = None
        self.q: A = None
        self.x: C = None
        self.o: B = None
        self.u: A = None
        self.s: C = None
        self.txt = txt

class D:
    def __init__(self, txt: str):
        self.r: E = None
        self.y: B = None
        self.o: B = None
        self.z: G = None
        self.q: B = None
        self.txt = txt

class E:
    def __init__(self, txt: str):
        self.s: D = None
        self.q: F = None
        self.u: G = None
        self.z: G = None
        self.x: G = None
        self.o: D = None
        self.txt = txt

class F:
    def __init__(self, txt: str):
        self.r: C = None
        self.x: C = None
        self.v: C = None
        self.p: E = None
        self.s: E = None
        self.o: C = None
        self.txt = txt

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

e = A("e")
a = B("a")
b = C("b")
m = D("m")
g = E("g")
d = F("d")
l = G("l")
n = C("n")
h = E("h")

e.t = d
a.z = l
a.r = l
a.y = d
b.z = g
b.q = e
b.u = e
b.x = n
b.s = n
b.o = a
m.r = h
m.y = a
m.o = a
m.q = a
m.z = l
g.s = m
g.o = m
g.q = d
g.u = l
g.z = l
g.x = l
d.r = b
d.x = b
d.v = n
d.o = n
d.p = g
d.s = h
l.z = g
l.y = h
l.q = d
l.x = a
n.z = g
n.q = e
n.u = e
n.x = b
n.s = b
n.o = a
h.s = m
h.o = m
h.q = d
h.u = l
h.z = l
h.x = l
assert l.z.o.z.y.q.s.txt == "h"