class A:
    def __init__(self, txt: str):
        self.t: B = None
        self.y: C = None
        self.u: A = None
        self.r: A = None
        self.v: A = None
        self.txt = txt

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

class C:
    def __init__(self, txt: str):
        self.y: D = None
        self.s: B = None
        self.r: E = None
        self.v: B = None
        self.x: D = None
        self.txt = txt

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

class E:
    def __init__(self, txt: str):
        self.s: D = None
        self.z: E = None
        self.o: A = None
        self.t: C = None
        self.w: E = None
        self.q: D = None
        self.txt = txt

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

h = A("h")
c = B("c")
i = C("i")
e = D("e")
l = E("l")
m = F("m")
d = F("d")
n = A("n")
g = C("g")
k = E("k")

h.t = c
h.y = g
h.u = n
h.r = n
h.v = n
c.r = n
i.y = e
i.x = e
i.s = c
i.v = c
i.r = k
e.r = h
e.o = d
e.x = d
e.q = m
l.s = e
l.q = e
l.z = k
l.w = k
l.o = n
l.t = g
m.r = c
m.u = e
m.s = e
m.y = n
m.p = g
m.o = g
d.r = c
d.u = e
d.s = e
d.y = h
d.p = i
d.o = i
n.t = c
n.y = g
n.u = h
n.r = h
n.v = h
g.y = e
g.x = e
g.s = c
g.v = c
g.r = k
k.s = e
k.q = e
k.z = l
k.w = l
k.o = n
k.t = g
assert h.u.y.s.r.t.r.u.txt == "
class A:
    def __init__(self, txt: str):
        self.t: B = None
        self.y: C = None
        self.u: A = None
        self.r: A = None
        self.v: A = None
        self.txt = txt

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

class C:
    def __init__(self, txt: str):
        self.y: D = None
        self.s: B = None
        self.r: E = None
        self.v: B = None
        self.x: D = None
        self.txt = txt

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

class E:
    def __init__(self, txt: str):
        self.s: D = None
        self.z: E = None
        self.o: A = None
        self.t: C = None
        self.w: E = None
        self.q: D = None
        self.txt = txt

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

h = A("h")
c = B("c")
i = C("i")
e = D("e")
l = E("l")
m = F("m")
d = F("d")
n = A("n")
g = C("g")
k = E("k")

h.t = c
h.y = g
h.u = n
h.r = n
h.v = n
c.r = n
i.y = e
i.x = e
i.s = c
i.v = c
i.r = k
e.r = h
e.o = d
e.x = d
e.q = m
l.s = e
l.q = e
l.z = k
l.w = k
l.o = n
l.t = g
m.r = c
m.u = e
m.s = e
m.y = n
m.p = g
m.o = g
d.r = c
d.u = e
d.s = e
d.y = h
d.p = i
d.o = i
n.t = c
n.y = g
n.u = h
n.r = h
n.v = h
g.y = e
g.x = e
g.s = c
g.v = c
g.r = k
k.s = e
k.q = e
k.z = l
k.w = l
k.o = n
k.t = g
assert h.u.y.s.r.t.r.u.txt == "h"