class A:
    def __init__(self, txt: str):
        self.t: H = None
        self.y: H = None
        self.u: H = None
        self.v: C = None
        self.s: B = None
        self.z: E = None
        self.q: E = None
        self.txt = txt

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

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

class D:
    def __init__(self, txt: str):
        self.x: D = None
        self.w: H = None
        self.q: C = None
        self.t: F = None
        self.txt = txt

class E:
    def __init__(self, txt: str):
        self.v: H = None
        self.w: C = None
        self.p: B = None
        self.r: H = None
        self.q: B = None
        self.x: H = None
        self.s: C = None
        self.txt = txt

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

class G:
    def __init__(self, txt: str):
        self.s: A = None
        self.q: H = None
        self.x: A = None
        self.o: H = None
        self.w: A = None
        self.v: C = None
        self.txt = txt

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

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

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

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

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

class D:
    def __init__(self, txt: str):
        self.x: D = None
        self.w: H = None
        self.q: C = None
        self.t: F = None
        self.txt = txt

class E:
    def __init__(self, txt: str):
        self.v: H = None
        self.w: C = None
        self.p: B = None
        self.r: H = None
        self.q: B = None
        self.x: H = None
        self.s: C = None
        self.txt = txt

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

class G:
    def __init__(self, txt: str):
        self.s: A = None
        self.q: H = None
        self.x: A = None
        self.o: H = None
        self.w: A = None
        self.v: C = None
        self.txt = txt

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

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

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