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

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

class C:
    def __init__(self, txt: str):
        self.w: D = None
        self.r: D = None
        self.u: F = None
        self.y: H = None
        self.z: D = None
        self.s: F = None
        self.x: H = None
        self.o: F = None
        self.txt = txt

class D:
    def __init__(self, txt: str):
        self.p: E = None
        self.u: C = None
        self.o: E = None
        self.w: A = None
        self.txt = txt

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

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

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

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

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

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

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

class C:
    def __init__(self, txt: str):
        self.w: D = None
        self.r: D = None
        self.u: F = None
        self.y: H = None
        self.z: D = None
        self.s: F = None
        self.x: H = None
        self.o: F = None
        self.txt = txt

class D:
    def __init__(self, txt: str):
        self.p: E = None
        self.u: C = None
        self.o: E = None
        self.w: A = None
        self.txt = txt

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

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

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

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

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

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