class A:
    def __init__(self, txt: str):
        self.z: G = None
        self.y: H = None
        self.t: H = None
        self.s: I = None
        self.v: H = None
        self.x: J = None
        self.r: E = None
        self.txt = txt

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

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

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

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

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

class G:
    def __init__(self, txt: str):
        self.p: A = None
        self.txt = txt

class H:
    def __init__(self, txt: str):
        self.y: G = None
        self.o: E = None
        self.x: I = None
        self.q: J = None
        self.z: G = None
        self.txt = txt

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

class J:
    def __init__(self, txt: str):
        self.x: E = None
        self.z: C = None
        self.t: E = None
        self.txt = txt

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

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

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

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

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

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

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

class G:
    def __init__(self, txt: str):
        self.p: A = None
        self.txt = txt

class H:
    def __init__(self, txt: str):
        self.y: G = None
        self.o: E = None
        self.x: I = None
        self.q: J = None
        self.z: G = None
        self.txt = txt

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

class J:
    def __init__(self, txt: str):
        self.x: E = None
        self.z: C = None
        self.t: E = None
        self.txt = txt

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

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