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

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

class C:
    def __init__(self, txt: str):
        self.u: D = None
        self.x: D = None
        self.p: F = None
        self.r: F = None
        self.o: D = None
        self.txt = txt

class D:
    def __init__(self, txt: str):
        self.s: H = None
        self.p: A = None
        self.z: B = None
        self.o: H = None
        self.q: H = None
        self.t: F = None
        self.txt = txt

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

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

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

class H:
    def __init__(self, txt: str):
        self.p: G = None
        self.u: A = None
        self.y: D = None
        self.txt = txt

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

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

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

class C:
    def __init__(self, txt: str):
        self.u: D = None
        self.x: D = None
        self.p: F = None
        self.r: F = None
        self.o: D = None
        self.txt = txt

class D:
    def __init__(self, txt: str):
        self.s: H = None
        self.p: A = None
        self.z: B = None
        self.o: H = None
        self.q: H = None
        self.t: F = None
        self.txt = txt

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

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

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

class H:
    def __init__(self, txt: str):
        self.p: G = None
        self.u: A = None
        self.y: D = None
        self.txt = txt

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

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