class A:
    def __init__(self, txt: str):
        self.z: G = None
        self.v: C = None
        self.w: I = None
        self.u: C = None
        self.s: H = None
        self.p: B = None
        self.txt = txt

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

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

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

class E:
    def __init__(self, txt: str):
        self.t: A = None
        self.s: C = None
        self.p: C = None
        self.q: C = None
        self.u: J = None
        self.r: A = None
        self.z: H = None
        self.txt = txt

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

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

class H:
    def __init__(self, txt: str):
        self.r: I = None
        self.p: B = None
        self.y: A = None
        self.w: E = None
        self.z: F = None
        self.t: A = None
        self.q: G = None
        self.x: B = None
        self.txt = txt

class I:
    def __init__(self, txt: str):
        self.q: B = None
        self.t: G = None
        self.txt = txt

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

m = A("m")
h = B("h")
k = C("k")
j = D("j")
b = E("b")
l = F("l")
g = G("g")
f = H("f")
c = I("c")
d = J("d")

m.z = g
m.v = k
m.u = k
m.w = c
m.s = f
m.p = h
h.w = b
h.r = g
h.x = j
h.s = j
h.o = j
h.t = f
h.v = c
h.q = m
h.y = m
h.p = k
k.o = l
k.w = g
k.s = g
k.q = b
k.v = h
k.t = j
k.z = j
j.p = g
j.y = g
j.s = g
j.q = g
j.r = h
j.o = c
j.v = c
j.t = f
j.x = b
j.u = k
b.t = m
b.r = m
b.s = k
b.p = k
b.q = k
b.u = d
b.z = f
l.z = b
l.y = j
l.w = j
g.t = f
f.r = c
f.p = h
f.x = h
f.y = m
f.t = m
f.w = b
f.z = l
f.q = g
c.q = h
c.t = g
d.w = j
d.q = h
assert j.t.q.t.x.p.txt == "
class A:
    def __init__(self, txt: str):
        self.z: G = None
        self.v: C = None
        self.w: I = None
        self.u: C = None
        self.s: H = None
        self.p: B = None
        self.txt = txt

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

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

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

class E:
    def __init__(self, txt: str):
        self.t: A = None
        self.s: C = None
        self.p: C = None
        self.q: C = None
        self.u: J = None
        self.r: A = None
        self.z: H = None
        self.txt = txt

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

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

class H:
    def __init__(self, txt: str):
        self.r: I = None
        self.p: B = None
        self.y: A = None
        self.w: E = None
        self.z: F = None
        self.t: A = None
        self.q: G = None
        self.x: B = None
        self.txt = txt

class I:
    def __init__(self, txt: str):
        self.q: B = None
        self.t: G = None
        self.txt = txt

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

m = A("m")
h = B("h")
k = C("k")
j = D("j")
b = E("b")
l = F("l")
g = G("g")
f = H("f")
c = I("c")
d = J("d")

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