class A:
    def __init__(self, txt: str):
        self.q: E = None
        self.txt = txt

class B:
    def __init__(self, txt: str):
        self.t: H = None
        self.q: D = None
        self.s: B = None
        self.x: F = None
        self.w: A = None
        self.o: A = None
        self.r: B = None
        self.u: H = None
        self.txt = txt

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

class D:
    def __init__(self, txt: str):
        self.s: A = None
        self.txt = txt

class E:
    def __init__(self, txt: str):
        self.v: A = None
        self.txt = txt

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

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

class H:
    def __init__(self, txt: str):
        self.w: G = None
        self.p: D = None
        self.t: F = None
        self.z: A = None
        self.txt = txt

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

n.q = j
e.t = d
e.q = m
e.s = g
e.r = g
e.x = h
e.w = n
e.o = n
e.u = b
a.v = h
a.o = b
a.t = k
m.s = n
j.v = n
h.p = m
h.s = e
k.w = m
k.x = g
k.t = g
k.q = n
k.p = b
k.u = j
k.z = a
k.r = a
b.w = k
b.p = m
b.t = h
b.z = n
g.t = d
g.q = m
g.s = e
g.r = e
g.x = h
g.w = n
g.o = n
g.u = b
d.w = k
d.p = m
d.t = h
d.z = n
assert h.s.q.s.q.v.q.v.q.txt == "
class A:
    def __init__(self, txt: str):
        self.q: E = None
        self.txt = txt

class B:
    def __init__(self, txt: str):
        self.t: H = None
        self.q: D = None
        self.s: B = None
        self.x: F = None
        self.w: A = None
        self.o: A = None
        self.r: B = None
        self.u: H = None
        self.txt = txt

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

class D:
    def __init__(self, txt: str):
        self.s: A = None
        self.txt = txt

class E:
    def __init__(self, txt: str):
        self.v: A = None
        self.txt = txt

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

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

class H:
    def __init__(self, txt: str):
        self.w: G = None
        self.p: D = None
        self.t: F = None
        self.z: A = None
        self.txt = txt

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

n.q = j
e.t = d
e.q = m
e.s = g
e.r = g
e.x = h
e.w = n
e.o = n
e.u = b
a.v = h
a.o = b
a.t = k
m.s = n
j.v = n
h.p = m
h.s = e
k.w = m
k.x = g
k.t = g
k.q = n
k.p = b
k.u = j
k.z = a
k.r = a
b.w = k
b.p = m
b.t = h
b.z = n
g.t = d
g.q = m
g.s = e
g.r = e
g.x = h
g.w = n
g.o = n
g.u = b
d.w = k
d.p = m
d.t = h
d.z = n
assert h.s.q.s.q.v.q.v.q.txt == "j"