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

class B:
    def __init__(self, txt: str):
        self.r: G = None
        self.o: I = None
        self.p: F = None
        self.s: A = None
        self.u: G = None
        self.txt = txt

class C:
    def __init__(self, txt: str):
        self.p: H = None
        self.w: B = None
        self.v: B = None
        self.y: H = None
        self.r: I = None
        self.z: F = None
        self.q: B = None
        self.t: J = None
        self.txt = txt

class D:
    def __init__(self, txt: str):
        self.z: J = None
        self.q: J = None
        self.r: H = None
        self.txt = txt

class E:
    def __init__(self, txt: str):
        self.r: H = None
        self.w: G = None
        self.v: C = None
        self.q: C = None
        self.p: G = None
        self.y: H = None
        self.t: D = None
        self.o: F = None
        self.u: I = None
        self.s: F = None
        self.txt = txt

class F:
    def __init__(self, txt: str):
        self.w: C = None
        self.r: C = None
        self.txt = txt

class G:
    def __init__(self, txt: str):
        self.q: J = None
        self.y: E = None
        self.txt = txt

class H:
    def __init__(self, txt: str):
        self.z: F = None
        self.y: E = None
        self.v: I = None
        self.o: D = None
        self.s: A = None
        self.r: B = None
        self.txt = txt

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

class J:
    def __init__(self, txt: str):
        self.o: E = None
        self.txt = txt

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

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

class B:
    def __init__(self, txt: str):
        self.r: G = None
        self.o: I = None
        self.p: F = None
        self.s: A = None
        self.u: G = None
        self.txt = txt

class C:
    def __init__(self, txt: str):
        self.p: H = None
        self.w: B = None
        self.v: B = None
        self.y: H = None
        self.r: I = None
        self.z: F = None
        self.q: B = None
        self.t: J = None
        self.txt = txt

class D:
    def __init__(self, txt: str):
        self.z: J = None
        self.q: J = None
        self.r: H = None
        self.txt = txt

class E:
    def __init__(self, txt: str):
        self.r: H = None
        self.w: G = None
        self.v: C = None
        self.q: C = None
        self.p: G = None
        self.y: H = None
        self.t: D = None
        self.o: F = None
        self.u: I = None
        self.s: F = None
        self.txt = txt

class F:
    def __init__(self, txt: str):
        self.w: C = None
        self.r: C = None
        self.txt = txt

class G:
    def __init__(self, txt: str):
        self.q: J = None
        self.y: E = None
        self.txt = txt

class H:
    def __init__(self, txt: str):
        self.z: F = None
        self.y: E = None
        self.v: I = None
        self.o: D = None
        self.s: A = None
        self.r: B = None
        self.txt = txt

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

class J:
    def __init__(self, txt: str):
        self.o: E = None
        self.txt = txt

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

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