class A:
    def __init__(self, txt: str):
        self.v: D = None
        self.p: B = None
        self.x: C = None
        self.t: H = None
        self.w: D = None
        self.s: F = None
        self.txt = txt

class B:
    def __init__(self, txt: str):
        self.q: A = None
        self.z: C = None
        self.w: C = None
        self.r: B = None
        self.u: D = None
        self.txt = txt

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

class D:
    def __init__(self, txt: str):
        self.p: A = None
        self.x: A = None
        self.q: A = None
        self.r: A = None
        self.w: A = None
        self.txt = txt

class E:
    def __init__(self, txt: str):
        self.u: D = None
        self.txt = txt

class F:
    def __init__(self, txt: str):
        self.s: E = None
        self.x: G = None
        self.u: D = None
        self.w: B = None
        self.p: B = None
        self.txt = txt

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

class H:
    def __init__(self, txt: str):
        self.q: D = None
        self.x: G = None
        self.u: E = None
        self.z: A = None
        self.r: G = None
        self.o: F = None
        self.txt = txt

h = A("h")
e = B("e")
l = C("l")
a = D("a")
n = E("n")
i = F("i")
f = G("f")
b = H("b")
d = B("d")

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

class B:
    def __init__(self, txt: str):
        self.q: A = None
        self.z: C = None
        self.w: C = None
        self.r: B = None
        self.u: D = None
        self.txt = txt

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

class D:
    def __init__(self, txt: str):
        self.p: A = None
        self.x: A = None
        self.q: A = None
        self.r: A = None
        self.w: A = None
        self.txt = txt

class E:
    def __init__(self, txt: str):
        self.u: D = None
        self.txt = txt

class F:
    def __init__(self, txt: str):
        self.s: E = None
        self.x: G = None
        self.u: D = None
        self.w: B = None
        self.p: B = None
        self.txt = txt

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

class H:
    def __init__(self, txt: str):
        self.q: D = None
        self.x: G = None
        self.u: E = None
        self.z: A = None
        self.r: G = None
        self.o: F = None
        self.txt = txt

h = A("h")
e = B("e")
l = C("l")
a = D("a")
n = E("n")
i = F("i")
f = G("f")
b = H("b")
d = B("d")

h.v = a
h.w = a
h.p = e
h.x = l
h.t = b
h.s = i
e.q = h
e.z = l
e.w = l
e.r = d
e.u = a
l.s = f
l.o = d
a.p = h
a.x = h
a.q = h
a.r = h
a.w = h
n.u = a
i.s = n
i.x = f
i.u = a
i.w = e
i.p = d
f.z = i
f.q = h
f.x = h
f.w = l
f.r = e
f.s = a
b.q = a
b.x = f
b.r = f
b.u = n
b.z = h
b.o = i
d.q = h
d.z = l
d.w = l
d.r = e
d.u = a
assert d.u.r.t.z.x.o.z.s.z.txt == "i"