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

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

class C:
    def __init__(self, txt: str):
        self.r: G = None
        self.txt = txt

class D:
    def __init__(self, txt: str):
        self.o: B = None
        self.txt = txt

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

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

class G:
    def __init__(self, txt: str):
        self.y: C = None
        self.txt = txt

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

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

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

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

class C:
    def __init__(self, txt: str):
        self.r: G = None
        self.txt = txt

class D:
    def __init__(self, txt: str):
        self.o: B = None
        self.txt = txt

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

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

class G:
    def __init__(self, txt: str):
        self.y: C = None
        self.txt = txt

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

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

i.o = k
i.t = a
i.r = e
f.u = e
f.y = h
h.r = e
a.o = f
m.r = k
k.p = f
k.u = l
e.y = h
c.r = f
c.v = f
c.s = f
c.w = m
c.u = m
c.q = n
l.r = f
l.v = f
l.s = f
l.w = m
l.u = m
l.q = n
n.r = f
n.v = f
n.s = f
n.w = m
n.u = m
n.q = c
assert l.v.u.y.r.y.r.y.r.txt == "e"