class A:
    def __init__(self, txt: str):
        self.p: A = None
        self.w: B = None
        self.t: D = None
        self.o: B = None
        self.r: B = None
        self.txt = txt

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

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

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

class E:
    def __init__(self, txt: str):
        self.z: B = None
        self.v: B = None
        self.w: E = None
        self.q: E = None
        self.txt = txt

i = A("i")
n = B("n")
f = C("f")
k = D("k")
j = E("j")
e = A("e")
m = B("m")
b = A("b")
l = E("l")

i.p = b
i.w = n
i.t = k
i.o = m
i.r = m
n.v = m
n.s = i
n.u = i
f.x = j
f.w = n
f.o = k
f.t = k
f.y = k
k.y = l
k.q = m
j.z = m
j.v = n
j.w = l
j.q = l
e.p = i
e.w = n
e.o = n
e.t = k
e.r = m
m.v = n
m.s = e
m.u = b
b.p = i
b.w = n
b.t = k
b.o = m
b.r = m
l.z = n
l.v = m
l.w = j
l.q = j
assert f.x.q.w.z.s.txt == "
class A:
    def __init__(self, txt: str):
        self.p: A = None
        self.w: B = None
        self.t: D = None
        self.o: B = None
        self.r: B = None
        self.txt = txt

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

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

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

class E:
    def __init__(self, txt: str):
        self.z: B = None
        self.v: B = None
        self.w: E = None
        self.q: E = None
        self.txt = txt

i = A("i")
n = B("n")
f = C("f")
k = D("k")
j = E("j")
e = A("e")
m = B("m")
b = A("b")
l = E("l")

i.p = b
i.w = n
i.t = k
i.o = m
i.r = m
n.v = m
n.s = i
n.u = i
f.x = j
f.w = n
f.o = k
f.t = k
f.y = k
k.y = l
k.q = m
j.z = m
j.v = n
j.w = l
j.q = l
e.p = i
e.w = n
e.o = n
e.t = k
e.r = m
m.v = n
m.s = e
m.u = b
b.p = i
b.w = n
b.t = k
b.o = m
b.r = m
l.z = n
l.v = m
l.w = j
l.q = j
assert f.x.q.w.z.s.txt == "e"