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

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

class C:
    def __init__(self, txt: str):
        self.x: H = None
        self.txt = txt

class D:
    def __init__(self, txt: str):
        self.p: G = None
        self.r: G = None
        self.q: A = None
        self.txt = txt

class E:
    def __init__(self, txt: str):
        self.v: F = None
        self.x: D = None
        self.r: H = None
        self.txt = txt

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

class G:
    def __init__(self, txt: str):
        self.s: C = None
        self.o: C = None
        self.t: E = None
        self.txt = txt

class H:
    def __init__(self, txt: str):
        self.y: G = None
        self.o: D = None
        self.p: D = None
        self.v: C = None
        self.txt = txt

j = A("j")
b = B("b")
c = C("c")
k = D("k")
m = E("m")
n = F("n")
f = G("f")
e = H("e")
a = G("a")
l = A("l")

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

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

class C:
    def __init__(self, txt: str):
        self.x: H = None
        self.txt = txt

class D:
    def __init__(self, txt: str):
        self.p: G = None
        self.r: G = None
        self.q: A = None
        self.txt = txt

class E:
    def __init__(self, txt: str):
        self.v: F = None
        self.x: D = None
        self.r: H = None
        self.txt = txt

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

class G:
    def __init__(self, txt: str):
        self.s: C = None
        self.o: C = None
        self.t: E = None
        self.txt = txt

class H:
    def __init__(self, txt: str):
        self.y: G = None
        self.o: D = None
        self.p: D = None
        self.v: C = None
        self.txt = txt

j = A("j")
b = B("b")
c = C("c")
k = D("k")
m = E("m")
n = F("n")
f = G("f")
e = H("e")
a = G("a")
l = A("l")

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