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

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

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

class D:
    def __init__(self, txt: str):
        self.v: J = None
        self.p: J = None
        self.x: I = None
        self.o: F = None
        self.txt = txt

class E:
    def __init__(self, txt: str):
        self.q: D = None
        self.z: A = None
        self.u: H = None
        self.t: H = None
        self.w: B = None
        self.txt = txt

class F:
    def __init__(self, txt: str):
        self.t: H = None
        self.o: A = None
        self.txt = txt

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

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

class I:
    def __init__(self, txt: str):
        self.z: G = None
        self.txt = txt

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

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

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

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

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

class D:
    def __init__(self, txt: str):
        self.v: J = None
        self.p: J = None
        self.x: I = None
        self.o: F = None
        self.txt = txt

class E:
    def __init__(self, txt: str):
        self.q: D = None
        self.z: A = None
        self.u: H = None
        self.t: H = None
        self.w: B = None
        self.txt = txt

class F:
    def __init__(self, txt: str):
        self.t: H = None
        self.o: A = None
        self.txt = txt

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

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

class I:
    def __init__(self, txt: str):
        self.z: G = None
        self.txt = txt

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

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

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