class A:
    def __init__(self, txt: str):
        self.o: I = None
        self.x: G = None
        self.q: E = None
        self.txt = txt

class B:
    def __init__(self, txt: str):
        self.s: C = None
        self.v: G = None
        self.r: E = None
        self.p: C = None
        self.x: D = None
        self.q: E = None
        self.z: D = None
        self.u: D = None
        self.o: G = None
        self.w: E = None
        self.txt = txt

class C:
    def __init__(self, txt: str):
        self.p: F = None
        self.q: B = None
        self.x: B = None
        self.o: A = None
        self.r: G = None
        self.v: A = None
        self.z: B = None
        self.t: H = None
        self.u: H = None
        self.txt = txt

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

class E:
    def __init__(self, txt: str):
        self.u: B = None
        self.x: A = None
        self.w: B = None
        self.txt = txt

class F:
    def __init__(self, txt: str):
        self.s: D = None
        self.p: D = None
        self.x: I = None
        self.y: D = None
        self.u: G = None
        self.txt = txt

class G:
    def __init__(self, txt: str):
        self.o: A = None
        self.s: H = None
        self.t: B = None
        self.w: D = None
        self.v: F = None
        self.p: H = None
        self.q: H = None
        self.txt = txt

class H:
    def __init__(self, txt: str):
        self.y: F = None
        self.x: B = None
        self.txt = txt

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

class J:
    def __init__(self, txt: str):
        self.w: H = None
        self.r: E = None
        self.o: G = None
        self.z: H = None
        self.s: B = None
        self.p: D = None
        self.x: D = None
        self.txt = txt

k = A("k")
m = B("m")
i = C("i")
c = D("c")
n = E("n")
b = F("b")
j = G("j")
e = H("e")
d = I("d")
g = J("g")

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

class B:
    def __init__(self, txt: str):
        self.s: C = None
        self.v: G = None
        self.r: E = None
        self.p: C = None
        self.x: D = None
        self.q: E = None
        self.z: D = None
        self.u: D = None
        self.o: G = None
        self.w: E = None
        self.txt = txt

class C:
    def __init__(self, txt: str):
        self.p: F = None
        self.q: B = None
        self.x: B = None
        self.o: A = None
        self.r: G = None
        self.v: A = None
        self.z: B = None
        self.t: H = None
        self.u: H = None
        self.txt = txt

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

class E:
    def __init__(self, txt: str):
        self.u: B = None
        self.x: A = None
        self.w: B = None
        self.txt = txt

class F:
    def __init__(self, txt: str):
        self.s: D = None
        self.p: D = None
        self.x: I = None
        self.y: D = None
        self.u: G = None
        self.txt = txt

class G:
    def __init__(self, txt: str):
        self.o: A = None
        self.s: H = None
        self.t: B = None
        self.w: D = None
        self.v: F = None
        self.p: H = None
        self.q: H = None
        self.txt = txt

class H:
    def __init__(self, txt: str):
        self.y: F = None
        self.x: B = None
        self.txt = txt

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

class J:
    def __init__(self, txt: str):
        self.w: H = None
        self.r: E = None
        self.o: G = None
        self.z: H = None
        self.s: B = None
        self.p: D = None
        self.x: D = None
        self.txt = txt

k = A("k")
m = B("m")
i = C("i")
c = D("c")
n = E("n")
b = F("b")
j = G("j")
e = H("e")
d = I("d")
g = J("g")

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