class A:
    def __init__(self, txt: str):
        self.r: E = None
        self.z: B = None
        self.o: E = None
        self.t: C = None
        self.s: F = None
        self.txt = txt

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

class C:
    def __init__(self, txt: str):
        self.x: B = None
        self.o: F = None
        self.txt = txt

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

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

class F:
    def __init__(self, txt: str):
        self.t: G = None
        self.z: A = None
        self.v: E = None
        self.q: C = None
        self.txt = txt

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

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

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

h.r = c
h.o = c
h.z = a
h.t = n
h.s = f
a.p = m
a.o = m
a.s = m
a.t = i
a.u = f
a.w = f
a.y = d
a.z = h
n.x = a
n.o = g
i.q = a
i.r = f
c.z = f
c.q = f
c.y = g
f.t = m
f.z = h
f.v = c
f.q = n
m.w = i
m.v = n
m.z = a
d.x = l
d.q = f
g.t = m
g.z = h
g.v = c
g.q = n
l.w = i
l.v = n
l.z = a
assert d.x.z.w.v.q.q.x.t.txt == "
class A:
    def __init__(self, txt: str):
        self.r: E = None
        self.z: B = None
        self.o: E = None
        self.t: C = None
        self.s: F = None
        self.txt = txt

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

class C:
    def __init__(self, txt: str):
        self.x: B = None
        self.o: F = None
        self.txt = txt

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

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

class F:
    def __init__(self, txt: str):
        self.t: G = None
        self.z: A = None
        self.v: E = None
        self.q: C = None
        self.txt = txt

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

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

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

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