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

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

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

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

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

j = A("j")
g = B("g")
n = C("n")
l = D("l")
c = E("c")
h = A("h")
i = E("i")
m = C("m")

j.q = h
j.o = h
j.p = c
j.y = l
j.x = i
g.y = i
g.z = i
g.x = j
g.r = j
g.o = h
n.y = l
n.o = m
l.s = g
l.w = g
l.u = c
l.o = h
l.q = i
c.r = g
c.y = g
c.q = g
c.p = i
c.x = i
h.q = j
h.o = j
h.p = c
h.x = c
h.y = l
i.r = g
i.y = g
i.q = g
i.p = c
i.x = c
m.y = l
m.o = n
assert n.o.y.s.z.txt == "
class A:
    def __init__(self, txt: str):
        self.q: A = None
        self.o: A = None
        self.p: E = None
        self.y: D = None
        self.x: E = None
        self.txt = txt

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

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

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

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

j = A("j")
g = B("g")
n = C("n")
l = D("l")
c = E("c")
h = A("h")
i = E("i")
m = C("m")

j.q = h
j.o = h
j.p = c
j.y = l
j.x = i
g.y = i
g.z = i
g.x = j
g.r = j
g.o = h
n.y = l
n.o = m
l.s = g
l.w = g
l.u = c
l.o = h
l.q = i
c.r = g
c.y = g
c.q = g
c.p = i
c.x = i
h.q = j
h.o = j
h.p = c
h.x = c
h.y = l
i.r = g
i.y = g
i.q = g
i.p = c
i.x = c
m.y = l
m.o = n
assert n.o.y.s.z.txt == "i"