class A:
    def __init__(self, txt: str):
        self.q: E = None
        self.u: C = None
        self.txt = txt

class B:
    def __init__(self, txt: str):
        self.v: B = None
        self.u: D = None
        self.x: F = None
        self.p: E = None
        self.y: B = None
        self.t: B = None
        self.s: B = None
        self.txt = txt

class C:
    def __init__(self, txt: str):
        self.p: C = None
        self.x: C = None
        self.t: D = None
        self.o: C = None
        self.z: A = None
        self.txt = txt

class D:
    def __init__(self, txt: str):
        self.r: B = None
        self.x: A = None
        self.v: F = None
        self.p: F = None
        self.txt = txt

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

class F:
    def __init__(self, txt: str):
        self.q: G = None
        self.t: D = None
        self.o: E = None
        self.z: A = None
        self.y: E = None
        self.v: G = None
        self.txt = txt

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

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

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

class B:
    def __init__(self, txt: str):
        self.v: B = None
        self.u: D = None
        self.x: F = None
        self.p: E = None
        self.y: B = None
        self.t: B = None
        self.s: B = None
        self.txt = txt

class C:
    def __init__(self, txt: str):
        self.p: C = None
        self.x: C = None
        self.t: D = None
        self.o: C = None
        self.z: A = None
        self.txt = txt

class D:
    def __init__(self, txt: str):
        self.r: B = None
        self.x: A = None
        self.v: F = None
        self.p: F = None
        self.txt = txt

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

class F:
    def __init__(self, txt: str):
        self.q: G = None
        self.t: D = None
        self.o: E = None
        self.z: A = None
        self.y: E = None
        self.v: G = None
        self.txt = txt

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

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

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