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

class B:
    def __init__(self, txt: str):
        self.x: C = None
        self.y: A = None
        self.v: B = None
        self.w: D = None
        self.txt = txt

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

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

class E:
    def __init__(self, txt: str):
        self.w: C = None
        self.x: D = None
        self.o: B = None
        self.y: B = None
        self.txt = txt

l = A("l")
h = B("h")
e = C("e")
c = D("c")
f = E("f")
j = C("j")
a = A("a")
k = B("k")
n = D("n")

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

class B:
    def __init__(self, txt: str):
        self.x: C = None
        self.y: A = None
        self.v: B = None
        self.w: D = None
        self.txt = txt

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

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

class E:
    def __init__(self, txt: str):
        self.w: C = None
        self.x: D = None
        self.o: B = None
        self.y: B = None
        self.txt = txt

l = A("l")
h = B("h")
e = C("e")
c = D("c")
f = E("f")
j = C("j")
a = A("a")
k = B("k")
n = D("n")

l.u = c
l.y = n
l.o = k
h.x = e
h.y = l
h.v = k
h.w = n
e.s = c
e.q = n
c.x = k
c.v = k
c.t = f
c.s = n
f.w = j
f.x = c
f.o = h
f.y = h
j.s = n
j.q = c
a.u = c
a.y = n
a.o = h
k.x = j
k.y = a
k.v = h
k.w = n
n.x = h
n.t = f
n.v = k
n.s = c
assert n.s.s.s.x.y.u.t.x.txt == "c"