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

class B:
    def __init__(self, txt: str):
        self.t: H = None
        self.q: H = None
        self.txt = txt

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

class D:
    def __init__(self, txt: str):
        self.r: E = None
        self.v: A = None
        self.z: F = None
        self.q: A = None
        self.x: A = None
        self.o: A = None
        self.y: C = None
        self.txt = txt

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

class F:
    def __init__(self, txt: str):
        self.o: G = None
        self.u: G = None
        self.y: B = None
        self.x: G = None
        self.w: H = None
        self.q: G = None
        self.v: H = None
        self.txt = txt

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

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

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

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

class B:
    def __init__(self, txt: str):
        self.t: H = None
        self.q: H = None
        self.txt = txt

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

class D:
    def __init__(self, txt: str):
        self.r: E = None
        self.v: A = None
        self.z: F = None
        self.q: A = None
        self.x: A = None
        self.o: A = None
        self.y: C = None
        self.txt = txt

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

class F:
    def __init__(self, txt: str):
        self.o: G = None
        self.u: G = None
        self.y: B = None
        self.x: G = None
        self.w: H = None
        self.q: G = None
        self.v: H = None
        self.txt = txt

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

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

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

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