class A:
    def __init__(self, txt: str):
        self.x: G = None
        self.v: H = None
        self.t: D = None
        self.p: D = None
        self.o: G = None
        self.u: H = None
        self.txt = txt

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

class C:
    def __init__(self, txt: str):
        self.w: F = None
        self.y: F = None
        self.o: D = None
        self.s: E = None
        self.u: I = None
        self.t: E = None
        self.r: A = None
        self.txt = txt

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

class E:
    def __init__(self, txt: str):
        self.t: G = None
        self.txt = txt

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

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

class H:
    def __init__(self, txt: str):
        self.t: G = None
        self.o: I = None
        self.s: G = None
        self.p: D = None
        self.x: D = None
        self.v: B = None
        self.u: I = None
        self.w: I = None
        self.txt = txt

class I:
    def __init__(self, txt: str):
        self.w: A = None
        self.p: C = None
        self.y: F = None
        self.z: B = None
        self.q: F = None
        self.v: D = None
        self.x: A = None
        self.txt = txt

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

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

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

class C:
    def __init__(self, txt: str):
        self.w: F = None
        self.y: F = None
        self.o: D = None
        self.s: E = None
        self.u: I = None
        self.t: E = None
        self.r: A = None
        self.txt = txt

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

class E:
    def __init__(self, txt: str):
        self.t: G = None
        self.txt = txt

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

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

class H:
    def __init__(self, txt: str):
        self.t: G = None
        self.o: I = None
        self.s: G = None
        self.p: D = None
        self.x: D = None
        self.v: B = None
        self.u: I = None
        self.w: I = None
        self.txt = txt

class I:
    def __init__(self, txt: str):
        self.w: A = None
        self.p: C = None
        self.y: F = None
        self.z: B = None
        self.q: F = None
        self.v: D = None
        self.x: A = None
        self.txt = txt

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

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