class A:
    def __init__(self, txt: str):
        self.p: J = None
        self.w: J = None
        self.y: H = None
        self.t: J = None
        self.txt = txt

class B:
    def __init__(self, txt: str):
        self.s: G = None
        self.v: J = None
        self.q: A = None
        self.txt = txt

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

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

class E:
    def __init__(self, txt: str):
        self.o: G = None
        self.p: I = None
        self.q: A = None
        self.v: B = None
        self.u: D = None
        self.x: F = None
        self.txt = txt

class F:
    def __init__(self, txt: str):
        self.y: D = None
        self.z: G = None
        self.p: A = None
        self.q: J = None
        self.x: D = None
        self.o: J = None
        self.txt = txt

class G:
    def __init__(self, txt: str):
        self.t: F = None
        self.s: E = None
        self.o: C = None
        self.z: C = None
        self.r: D = None
        self.txt = txt

class H:
    def __init__(self, txt: str):
        self.y: D = None
        self.v: G = None
        self.txt = txt

class I:
    def __init__(self, txt: str):
        self.q: H = None
        self.w: A = None
        self.y: C = None
        self.v: G = None
        self.txt = txt

class J:
    def __init__(self, txt: str):
        self.u: H = None
        self.z: G = None
        self.r: A = None
        self.txt = txt

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

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

class B:
    def __init__(self, txt: str):
        self.s: G = None
        self.v: J = None
        self.q: A = None
        self.txt = txt

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

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

class E:
    def __init__(self, txt: str):
        self.o: G = None
        self.p: I = None
        self.q: A = None
        self.v: B = None
        self.u: D = None
        self.x: F = None
        self.txt = txt

class F:
    def __init__(self, txt: str):
        self.y: D = None
        self.z: G = None
        self.p: A = None
        self.q: J = None
        self.x: D = None
        self.o: J = None
        self.txt = txt

class G:
    def __init__(self, txt: str):
        self.t: F = None
        self.s: E = None
        self.o: C = None
        self.z: C = None
        self.r: D = None
        self.txt = txt

class H:
    def __init__(self, txt: str):
        self.y: D = None
        self.v: G = None
        self.txt = txt

class I:
    def __init__(self, txt: str):
        self.q: H = None
        self.w: A = None
        self.y: C = None
        self.v: G = None
        self.txt = txt

class J:
    def __init__(self, txt: str):
        self.u: H = None
        self.z: G = None
        self.r: A = None
        self.txt = txt

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

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