class A:
    def __init__(self, txt: str):
        self.s: E = None
        self.o: E = None
        self.txt = txt

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

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

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

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

c = A("c")
e = B("e")
m = C("m")
k = D("k")
l = E("l")
j = D("j")

c.s = l
c.o = l
e.t = m
m.s = l
m.t = k
m.v = k
k.q = l
k.r = l
k.o = l
k.p = e
k.t = m
l.y = c
l.u = c
l.o = c
l.v = m
l.r = m
j.q = l
j.r = l
j.o = l
j.p = e
j.t = m
assert j.t.v.t.s.v.v.txt == "
class A:
    def __init__(self, txt: str):
        self.s: E = None
        self.o: E = None
        self.txt = txt

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

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

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

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

c = A("c")
e = B("e")
m = C("m")
k = D("k")
l = E("l")
j = D("j")

c.s = l
c.o = l
e.t = m
m.s = l
m.t = k
m.v = k
k.q = l
k.r = l
k.o = l
k.p = e
k.t = m
l.y = c
l.u = c
l.o = c
l.v = m
l.r = m
j.q = l
j.r = l
j.o = l
j.p = e
j.t = m
assert j.t.v.t.s.v.v.txt == "k"