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

class B:
    def __init__(self, txt: str):
        self.t: I = None
        self.u: A = None
        self.txt = txt

class C:
    def __init__(self, txt: str):
        self.x: I = None
        self.s: G = None
        self.r: H = None
        self.z: I = None
        self.y: E = None
        self.w: D = None
        self.txt = txt

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

class E:
    def __init__(self, txt: str):
        self.p: F = None
        self.u: I = None
        self.txt = txt

class F:
    def __init__(self, txt: str):
        self.x: A = None
        self.w: B = None
        self.t: E = None
        self.s: E = None
        self.q: C = None
        self.u: D = None
        self.z: I = None
        self.txt = txt

class G:
    def __init__(self, txt: str):
        self.x: E = None
        self.w: I = None
        self.r: I = None
        self.p: D = None
        self.o: E = None
        self.t: E = None
        self.z: B = None
        self.v: E = None
        self.y: D = None
        self.txt = txt

class H:
    def __init__(self, txt: str):
        self.v: A = None
        self.x: F = None
        self.r: B = None
        self.q: F = None
        self.txt = txt

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

c = A("c")
l = B("l")
h = C("h")
i = D("i")
g = E("g")
a = F("a")
b = G("b")
f = H("f")
k = I("k")

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

class B:
    def __init__(self, txt: str):
        self.t: I = None
        self.u: A = None
        self.txt = txt

class C:
    def __init__(self, txt: str):
        self.x: I = None
        self.s: G = None
        self.r: H = None
        self.z: I = None
        self.y: E = None
        self.w: D = None
        self.txt = txt

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

class E:
    def __init__(self, txt: str):
        self.p: F = None
        self.u: I = None
        self.txt = txt

class F:
    def __init__(self, txt: str):
        self.x: A = None
        self.w: B = None
        self.t: E = None
        self.s: E = None
        self.q: C = None
        self.u: D = None
        self.z: I = None
        self.txt = txt

class G:
    def __init__(self, txt: str):
        self.x: E = None
        self.w: I = None
        self.r: I = None
        self.p: D = None
        self.o: E = None
        self.t: E = None
        self.z: B = None
        self.v: E = None
        self.y: D = None
        self.txt = txt

class H:
    def __init__(self, txt: str):
        self.v: A = None
        self.x: F = None
        self.r: B = None
        self.q: F = None
        self.txt = txt

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

c = A("c")
l = B("l")
h = C("h")
i = D("i")
g = E("g")
a = F("a")
b = G("b")
f = H("f")
k = I("k")

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