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

class B:
    def __init__(self, txt: str):
        self.x: E = None
        self.txt = txt

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

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

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

c = A("c")
j = B("j")
h = C("h")
e = D("e")
n = E("n")
k = D("k")
d = C("d")
i = B("i")
g = A("g")

c.u = n
c.s = g
c.o = g
c.t = i
j.x = n
h.p = c
h.t = g
h.o = g
e.z = i
e.s = c
e.q = k
e.x = k
n.s = e
n.u = g
n.o = k
n.w = k
n.q = c
k.z = i
k.s = g
k.q = e
k.x = e
d.p = g
d.t = g
d.o = c
i.x = n
g.u = n
g.s = c
g.o = c
g.t = i
assert g.u.o.s.u.s.q.s.t.txt == "
class A:
    def __init__(self, txt: str):
        self.u: E = None
        self.s: A = None
        self.o: A = None
        self.t: B = None
        self.txt = txt

class B:
    def __init__(self, txt: str):
        self.x: E = None
        self.txt = txt

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

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

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

c = A("c")
j = B("j")
h = C("h")
e = D("e")
n = E("n")
k = D("k")
d = C("d")
i = B("i")
g = A("g")

c.u = n
c.s = g
c.o = g
c.t = i
j.x = n
h.p = c
h.t = g
h.o = g
e.z = i
e.s = c
e.q = k
e.x = k
n.s = e
n.u = g
n.o = k
n.w = k
n.q = c
k.z = i
k.s = g
k.q = e
k.x = e
d.p = g
d.t = g
d.o = c
i.x = n
g.u = n
g.s = c
g.o = c
g.t = i
assert g.u.o.s.u.s.q.s.t.txt == "i"