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

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

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

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

class E:
    def __init__(self, txt: str):
        self.u: C = None
        self.y: B = None
        self.v: A = None
        self.q: A = None
        self.p: D = None
        self.txt = txt

class F:
    def __init__(self, txt: str):
        self.p: B = None
        self.z: B = None
        self.txt = txt

k = A("k")
i = B("i")
h = C("h")
d = D("d")
c = E("c")
f = F("f")
m = D("m")
l = C("l")
g = F("g")

k.z = g
k.w = i
i.o = h
h.t = m
h.q = i
d.s = m
d.p = m
d.y = c
c.u = h
c.y = i
c.v = k
c.q = k
c.p = d
f.p = i
f.z = i
m.s = d
m.p = d
m.y = c
l.t = m
l.q = i
g.p = i
g.z = i
assert c.p.p.y.y.o.txt == "
class A:
    def __init__(self, txt: str):
        self.z: F = None
        self.w: B = None
        self.txt = txt

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

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

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

class E:
    def __init__(self, txt: str):
        self.u: C = None
        self.y: B = None
        self.v: A = None
        self.q: A = None
        self.p: D = None
        self.txt = txt

class F:
    def __init__(self, txt: str):
        self.p: B = None
        self.z: B = None
        self.txt = txt

k = A("k")
i = B("i")
h = C("h")
d = D("d")
c = E("c")
f = F("f")
m = D("m")
l = C("l")
g = F("g")

k.z = g
k.w = i
i.o = h
h.t = m
h.q = i
d.s = m
d.p = m
d.y = c
c.u = h
c.y = i
c.v = k
c.q = k
c.p = d
f.p = i
f.z = i
m.s = d
m.p = d
m.y = c
l.t = m
l.q = i
g.p = i
g.z = i
assert c.p.p.y.y.o.txt == "h"