class A:
    def __init__(self, txt: str):
        self.p: E = None
        self.q: B = None
        self.x: I = None
        self.t: B = None
        self.s: D = None
        self.txt = txt

class B:
    def __init__(self, txt: str):
        self.w: G = None
        self.t: A = None
        self.y: D = None
        self.x: C = None
        self.o: A = None
        self.v: D = None
        self.r: A = None
        self.s: D = None
        self.z: F = None
        self.txt = txt

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

class D:
    def __init__(self, txt: str):
        self.z: C = None
        self.u: A = None
        self.t: B = None
        self.v: I = None
        self.p: B = None
        self.y: G = None
        self.s: A = None
        self.q: A = None
        self.txt = txt

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

class F:
    def __init__(self, txt: str):
        self.o: B = None
        self.w: G = None
        self.r: C = None
        self.y: B = None
        self.t: I = None
        self.u: E = None
        self.p: A = None
        self.txt = txt

class G:
    def __init__(self, txt: str):
        self.s: H = None
        self.txt = txt

class H:
    def __init__(self, txt: str):
        self.v: D = None
        self.t: E = None
        self.y: C = None
        self.o: E = None
        self.z: G = None
        self.s: E = None
        self.r: E = None
        self.x: E = None
        self.u: A = None
        self.txt = txt

class I:
    def __init__(self, txt: str):
        self.p: E = None
        self.v: C = None
        self.o: C = None
        self.x: H = None
        self.txt = txt

i = A("i")
k = B("k")
d = C("d")
l = D("l")
f = E("f")
e = F("e")
b = G("b")
a = H("a")
j = I("j")
c = H("c")

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

class B:
    def __init__(self, txt: str):
        self.w: G = None
        self.t: A = None
        self.y: D = None
        self.x: C = None
        self.o: A = None
        self.v: D = None
        self.r: A = None
        self.s: D = None
        self.z: F = None
        self.txt = txt

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

class D:
    def __init__(self, txt: str):
        self.z: C = None
        self.u: A = None
        self.t: B = None
        self.v: I = None
        self.p: B = None
        self.y: G = None
        self.s: A = None
        self.q: A = None
        self.txt = txt

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

class F:
    def __init__(self, txt: str):
        self.o: B = None
        self.w: G = None
        self.r: C = None
        self.y: B = None
        self.t: I = None
        self.u: E = None
        self.p: A = None
        self.txt = txt

class G:
    def __init__(self, txt: str):
        self.s: H = None
        self.txt = txt

class H:
    def __init__(self, txt: str):
        self.v: D = None
        self.t: E = None
        self.y: C = None
        self.o: E = None
        self.z: G = None
        self.s: E = None
        self.r: E = None
        self.x: E = None
        self.u: A = None
        self.txt = txt

class I:
    def __init__(self, txt: str):
        self.p: E = None
        self.v: C = None
        self.o: C = None
        self.x: H = None
        self.txt = txt

i = A("i")
k = B("k")
d = C("d")
l = D("l")
f = E("f")
e = F("e")
b = G("b")
a = H("a")
j = I("j")
c = H("c")

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