class A:
    def __init__(self, txt: str):
        self.o: D = None
        self.s: J = None
        self.u: E = None
        self.p: I = None
        self.txt = txt

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

class C:
    def __init__(self, txt: str):
        self.p: F = None
        self.t: A = None
        self.s: A = None
        self.txt = txt

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

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

class F:
    def __init__(self, txt: str):
        self.v: B = None
        self.q: I = None
        self.txt = txt

class G:
    def __init__(self, txt: str):
        self.r: H = None
        self.w: C = None
        self.txt = txt

class H:
    def __init__(self, txt: str):
        self.w: B = None
        self.o: A = None
        self.z: B = None
        self.y: B = None
        self.s: E = None
        self.t: C = None
        self.u: C = None
        self.q: J = None
        self.txt = txt

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

class J:
    def __init__(self, txt: str):
        self.r: F = None
        self.txt = txt

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

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

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

class C:
    def __init__(self, txt: str):
        self.p: F = None
        self.t: A = None
        self.s: A = None
        self.txt = txt

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

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

class F:
    def __init__(self, txt: str):
        self.v: B = None
        self.q: I = None
        self.txt = txt

class G:
    def __init__(self, txt: str):
        self.r: H = None
        self.w: C = None
        self.txt = txt

class H:
    def __init__(self, txt: str):
        self.w: B = None
        self.o: A = None
        self.z: B = None
        self.y: B = None
        self.s: E = None
        self.t: C = None
        self.u: C = None
        self.q: J = None
        self.txt = txt

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

class J:
    def __init__(self, txt: str):
        self.r: F = None
        self.txt = txt

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

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