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

class B:
    def __init__(self, txt: str):
        self.y: I = None
        self.txt = txt

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

class D:
    def __init__(self, txt: str):
        self.y: I = None
        self.p: E = None
        self.v: A = None
        self.s: H = None
        self.z: F = None
        self.txt = txt

class E:
    def __init__(self, txt: str):
        self.v: A = None
        self.u: B = None
        self.t: B = None
        self.x: F = None
        self.p: I = None
        self.txt = txt

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

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

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

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

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

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

class B:
    def __init__(self, txt: str):
        self.y: I = None
        self.txt = txt

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

class D:
    def __init__(self, txt: str):
        self.y: I = None
        self.p: E = None
        self.v: A = None
        self.s: H = None
        self.z: F = None
        self.txt = txt

class E:
    def __init__(self, txt: str):
        self.v: A = None
        self.u: B = None
        self.t: B = None
        self.x: F = None
        self.p: I = None
        self.txt = txt

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

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

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

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

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

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