class A:
    def __init__(self, txt: str):
        self.v: B = None
        self.y: A = None
        self.o: A = None
        self.t: E = None
        self.txt = txt

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

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

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

class E:
    def __init__(self, txt: str):
        self.o: D = None
        self.p: B = None
        self.z: D = None
        self.x: D = None
        self.y: A = None
        self.txt = txt

k = A("k")
g = B("g")
l = C("l")
c = D("c")
a = E("a")
m = A("m")
d = E("d")
n = D("n")
e = D("e")
j = E("j")

k.v = g
k.y = m
k.o = m
k.t = d
g.s = k
l.s = c
l.u = m
c.v = l
a.o = c
a.z = c
a.p = g
a.x = n
a.y = m
m.v = g
m.y = k
m.o = k
m.t = j
d.o = e
d.x = e
d.p = g
d.z = c
d.y = k
n.v = l
e.v = l
j.o = e
j.z = e
j.p = g
j.x = n
j.y = m
assert c.v.u.v.s.v.s.txt == "
class A:
    def __init__(self, txt: str):
        self.v: B = None
        self.y: A = None
        self.o: A = None
        self.t: E = None
        self.txt = txt

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

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

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

class E:
    def __init__(self, txt: str):
        self.o: D = None
        self.p: B = None
        self.z: D = None
        self.x: D = None
        self.y: A = None
        self.txt = txt

k = A("k")
g = B("g")
l = C("l")
c = D("c")
a = E("a")
m = A("m")
d = E("d")
n = D("n")
e = D("e")
j = E("j")

k.v = g
k.y = m
k.o = m
k.t = d
g.s = k
l.s = c
l.u = m
c.v = l
a.o = c
a.z = c
a.p = g
a.x = n
a.y = m
m.v = g
m.y = k
m.o = k
m.t = j
d.o = e
d.x = e
d.p = g
d.z = c
d.y = k
n.v = l
e.v = l
j.o = e
j.z = e
j.p = g
j.x = n
j.y = m
assert c.v.u.v.s.v.s.txt == "k"