class A:
    def __init__(self, txt: str):
        self.w: C = None
        self.txt = txt

class B:
    def __init__(self, txt: str):
        self.p: E = None
        self.v: D = None
        self.u: A = None
        self.s: B = None
        self.z: C = None
        self.txt = txt

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

class D:
    def __init__(self, txt: str):
        self.x: A = None
        self.p: C = None
        self.txt = txt

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

l = A("l")
c = B("c")
a = C("a")
f = D("f")
e = E("e")
j = A("j")
d = B("d")
i = D("i")
b = C("b")

l.w = a
c.p = e
c.v = f
c.u = l
c.s = d
c.z = a
a.y = b
a.t = b
a.o = i
a.s = d
f.x = l
f.p = a
e.o = a
e.u = c
j.w = a
d.p = e
d.v = i
d.u = l
d.s = c
d.z = b
i.x = l
i.p = b
b.y = a
b.t = a
b.o = i
b.s = c
assert c.p.u.z.o.x.w.o.p.t.txt == "
class A:
    def __init__(self, txt: str):
        self.w: C = None
        self.txt = txt

class B:
    def __init__(self, txt: str):
        self.p: E = None
        self.v: D = None
        self.u: A = None
        self.s: B = None
        self.z: C = None
        self.txt = txt

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

class D:
    def __init__(self, txt: str):
        self.x: A = None
        self.p: C = None
        self.txt = txt

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

l = A("l")
c = B("c")
a = C("a")
f = D("f")
e = E("e")
j = A("j")
d = B("d")
i = D("i")
b = C("b")

l.w = a
c.p = e
c.v = f
c.u = l
c.s = d
c.z = a
a.y = b
a.t = b
a.o = i
a.s = d
f.x = l
f.p = a
e.o = a
e.u = c
j.w = a
d.p = e
d.v = i
d.u = l
d.s = c
d.z = b
i.x = l
i.p = b
b.y = a
b.t = a
b.o = i
b.s = c
assert c.p.u.z.o.x.w.o.p.t.txt == "a"