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

class B:
    def __init__(self, txt: str):
        self.u: J = None
        self.o: A = None
        self.v: E = None
        self.t: A = None
        self.s: F = None
        self.y: H = None
        self.z: E = None
        self.txt = txt

class C:
    def __init__(self, txt: str):
        self.s: B = None
        self.r: D = None
        self.p: H = None
        self.txt = txt

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

class E:
    def __init__(self, txt: str):
        self.p: J = None
        self.v: I = None
        self.s: D = None
        self.y: B = None
        self.txt = txt

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

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

class H:
    def __init__(self, txt: str):
        self.u: B = None
        self.z: F = None
        self.o: F = None
        self.s: B = None
        self.p: C = None
        self.r: J = None
        self.txt = txt

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

class J:
    def __init__(self, txt: str):
        self.t: B = None
        self.s: D = None
        self.w: C = None
        self.u: E = None
        self.p: D = None
        self.v: H = None
        self.y: H = None
        self.z: F = None
        self.q: A = None
        self.txt = txt

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

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

class B:
    def __init__(self, txt: str):
        self.u: J = None
        self.o: A = None
        self.v: E = None
        self.t: A = None
        self.s: F = None
        self.y: H = None
        self.z: E = None
        self.txt = txt

class C:
    def __init__(self, txt: str):
        self.s: B = None
        self.r: D = None
        self.p: H = None
        self.txt = txt

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

class E:
    def __init__(self, txt: str):
        self.p: J = None
        self.v: I = None
        self.s: D = None
        self.y: B = None
        self.txt = txt

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

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

class H:
    def __init__(self, txt: str):
        self.u: B = None
        self.z: F = None
        self.o: F = None
        self.s: B = None
        self.p: C = None
        self.r: J = None
        self.txt = txt

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

class J:
    def __init__(self, txt: str):
        self.t: B = None
        self.s: D = None
        self.w: C = None
        self.u: E = None
        self.p: D = None
        self.v: H = None
        self.y: H = None
        self.z: F = None
        self.q: A = None
        self.txt = txt

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

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