class A:
    def __init__(self, txt: str):
        self.u: E = None
        self.q: B = None
        self.r: C = None
        self.w: A = None
        self.txt = txt

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

class C:
    def __init__(self, txt: str):
        self.t: A = None
        self.q: A = None
        self.x: B = None
        self.z: A = None
        self.w: C = None
        self.txt = txt

class D:
    def __init__(self, txt: str):
        self.z: D = None
        self.y: B = None
        self.r: C = None
        self.txt = txt

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

k = A("k")
m = B("m")
b = C("b")
e = D("e")
a = E("a")
j = D("j")
i = C("i")
l = E("l")
d = A("d")
h = C("h")

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

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

class C:
    def __init__(self, txt: str):
        self.t: A = None
        self.q: A = None
        self.x: B = None
        self.z: A = None
        self.w: C = None
        self.txt = txt

class D:
    def __init__(self, txt: str):
        self.z: D = None
        self.y: B = None
        self.r: C = None
        self.txt = txt

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

k = A("k")
m = B("m")
b = C("b")
e = D("e")
a = E("a")
j = D("j")
i = C("i")
l = E("l")
d = A("d")
h = C("h")

k.u = l
k.q = m
k.r = b
k.w = d
m.t = e
m.o = i
m.q = i
b.t = k
b.q = k
b.x = m
b.z = d
b.w = i
e.z = j
e.y = m
e.r = i
a.q = m
a.v = m
a.z = m
a.t = l
a.u = h
j.z = e
j.y = m
j.r = h
i.t = k
i.z = k
i.q = d
i.x = m
i.w = h
l.q = m
l.v = m
l.z = m
l.t = a
l.u = i
d.u = l
d.q = m
d.r = i
d.w = k
h.t = k
h.q = k
h.z = k
h.x = m
h.w = i
assert j.z.z.y.t.r.txt == "i"