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

class B:
    def __init__(self, txt: str):
        self.w: C = None
        self.z: D = None
        self.r: F = None
        self.s: J = None
        self.txt = txt

class C:
    def __init__(self, txt: str):
        self.v: A = None
        self.z: F = None
        self.w: D = None
        self.s: A = None
        self.r: H = None
        self.txt = txt

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

class E:
    def __init__(self, txt: str):
        self.p: H = None
        self.z: A = None
        self.txt = txt

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

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

class H:
    def __init__(self, txt: str):
        self.v: B = None
        self.y: E = None
        self.o: I = None
        self.x: C = None
        self.txt = txt

class I:
    def __init__(self, txt: str):
        self.s: D = None
        self.u: D = None
        self.t: H = None
        self.w: G = None
        self.o: D = None
        self.x: E = None
        self.txt = txt

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

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

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

class B:
    def __init__(self, txt: str):
        self.w: C = None
        self.z: D = None
        self.r: F = None
        self.s: J = None
        self.txt = txt

class C:
    def __init__(self, txt: str):
        self.v: A = None
        self.z: F = None
        self.w: D = None
        self.s: A = None
        self.r: H = None
        self.txt = txt

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

class E:
    def __init__(self, txt: str):
        self.p: H = None
        self.z: A = None
        self.txt = txt

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

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

class H:
    def __init__(self, txt: str):
        self.v: B = None
        self.y: E = None
        self.o: I = None
        self.x: C = None
        self.txt = txt

class I:
    def __init__(self, txt: str):
        self.s: D = None
        self.u: D = None
        self.t: H = None
        self.w: G = None
        self.o: D = None
        self.x: E = None
        self.txt = txt

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

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

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