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

class B:
    def __init__(self, txt: str):
        self.v: D = None
        self.p: D = None
        self.t: D = None
        self.u: F = None
        self.w: C = None
        self.x: D = None
        self.txt = txt

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

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

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

class F:
    def __init__(self, txt: str):
        self.y: C = None
        self.q: A = None
        self.txt = txt

k = A("k")
h = B("h")
f = C("f")
i = D("i")
b = E("b")
j = F("j")
e = A("e")
g = F("g")
l = B("l")
a = F("a")

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

class B:
    def __init__(self, txt: str):
        self.v: D = None
        self.p: D = None
        self.t: D = None
        self.u: F = None
        self.w: C = None
        self.x: D = None
        self.txt = txt

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

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

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

class F:
    def __init__(self, txt: str):
        self.y: C = None
        self.q: A = None
        self.txt = txt

k = A("k")
h = B("h")
f = C("f")
i = D("i")
b = E("b")
j = F("j")
e = A("e")
g = F("g")
l = B("l")
a = F("a")

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