class A:
    def __init__(self, txt: str):
        self.o: G = None
        self.txt = txt

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

class C:
    def __init__(self, txt: str):
        self.w: B = None
        self.p: F = None
        self.o: F = None
        self.z: F = None
        self.x: I = None
        self.s: B = None
        self.txt = txt

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

class E:
    def __init__(self, txt: str):
        self.t: A = None
        self.y: A = None
        self.u: I = None
        self.v: I = None
        self.w: C = None
        self.r: H = None
        self.txt = txt

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

class G:
    def __init__(self, txt: str):
        self.w: B = None
        self.txt = txt

class H:
    def __init__(self, txt: str):
        self.q: C = None
        self.x: C = None
        self.y: D = None
        self.v: A = None
        self.txt = txt

class I:
    def __init__(self, txt: str):
        self.t: B = None
        self.p: F = None
        self.w: B = None
        self.txt = txt

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

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

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

class C:
    def __init__(self, txt: str):
        self.w: B = None
        self.p: F = None
        self.o: F = None
        self.z: F = None
        self.x: I = None
        self.s: B = None
        self.txt = txt

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

class E:
    def __init__(self, txt: str):
        self.t: A = None
        self.y: A = None
        self.u: I = None
        self.v: I = None
        self.w: C = None
        self.r: H = None
        self.txt = txt

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

class G:
    def __init__(self, txt: str):
        self.w: B = None
        self.txt = txt

class H:
    def __init__(self, txt: str):
        self.q: C = None
        self.x: C = None
        self.y: D = None
        self.v: A = None
        self.txt = txt

class I:
    def __init__(self, txt: str):
        self.t: B = None
        self.p: F = None
        self.w: B = None
        self.txt = txt

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

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