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

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

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

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

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

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

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

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

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

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

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

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

f.v = c
f.z = m
f.r = h
f.y = k
e.w = k
e.s = k
c.q = l
c.w = e
c.u = j
l.v = e
m.x = j
m.y = j
m.v = j
m.o = c
m.r = k
b.v = c
b.z = m
b.r = h
b.y = k
h.v = a
j.x = m
j.y = m
j.v = m
j.o = c
j.r = k
k.v = c
k.z = j
k.r = l
k.y = f
a.w = f
a.s = k
assert b.y.v.w.w.v.w.s.txt == "k"