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

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

class C:
    def __init__(self, txt: str):
        self.q: D = None
        self.y: E = None
        self.t: B = None
        self.p: G = None
        self.txt = txt

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

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

class F:
    def __init__(self, txt: str):
        self.o: A = None
        self.x: G = None
        self.w: D = None
        self.v: I = None
        self.r: B = None
        self.u: C = None
        self.txt = txt

class G:
    def __init__(self, txt: str):
        self.z: E = None
        self.y: C = None
        self.o: A = None
        self.q: C = None
        self.r: B = None
        self.v: D = None
        self.s: C = None
        self.t: I = None
        self.txt = txt

class H:
    def __init__(self, txt: str):
        self.u: D = None
        self.o: D = None
        self.s: A = None
        self.q: G = None
        self.txt = txt

class I:
    def __init__(self, txt: str):
        self.v: A = None
        self.p: F = None
        self.o: E = None
        self.x: F = None
        self.r: C = None
        self.u: D = None
        self.txt = txt

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

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

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

class C:
    def __init__(self, txt: str):
        self.q: D = None
        self.y: E = None
        self.t: B = None
        self.p: G = None
        self.txt = txt

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

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

class F:
    def __init__(self, txt: str):
        self.o: A = None
        self.x: G = None
        self.w: D = None
        self.v: I = None
        self.r: B = None
        self.u: C = None
        self.txt = txt

class G:
    def __init__(self, txt: str):
        self.z: E = None
        self.y: C = None
        self.o: A = None
        self.q: C = None
        self.r: B = None
        self.v: D = None
        self.s: C = None
        self.t: I = None
        self.txt = txt

class H:
    def __init__(self, txt: str):
        self.u: D = None
        self.o: D = None
        self.s: A = None
        self.q: G = None
        self.txt = txt

class I:
    def __init__(self, txt: str):
        self.v: A = None
        self.p: F = None
        self.o: E = None
        self.x: F = None
        self.r: C = None
        self.u: D = None
        self.txt = txt

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

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