class A:
    def __init__(self, txt: str):
        self.o: H = None
        self.p: H = None
        self.q: E = None
        self.x: I = None
        self.z: E = None
        self.r: F = None
        self.txt = txt

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

class C:
    def __init__(self, txt: str):
        self.x: F = None
        self.q: A = None
        self.y: E = None
        self.w: G = None
        self.u: J = None
        self.p: J = None
        self.txt = txt

class D:
    def __init__(self, txt: str):
        self.p: J = None
        self.s: H = None
        self.y: G = None
        self.t: H = None
        self.q: A = None
        self.txt = txt

class E:
    def __init__(self, txt: str):
        self.y: C = None
        self.txt = txt

class F:
    def __init__(self, txt: str):
        self.t: D = None
        self.w: J = None
        self.y: I = None
        self.x: C = None
        self.u: A = None
        self.r: D = None
        self.q: J = None
        self.z: C = None
        self.v: G = None
        self.txt = txt

class G:
    def __init__(self, txt: str):
        self.r: E = None
        self.o: C = None
        self.v: F = None
        self.w: D = None
        self.z: D = None
        self.u: D = None
        self.txt = txt

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

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

class J:
    def __init__(self, txt: str):
        self.z: F = None
        self.u: C = None
        self.o: I = None
        self.p: H = None
        self.s: F = None
        self.v: B = None
        self.r: I = None
        self.txt = txt

d = A("d")
a = B("a")
e = C("e")
n = D("n")
j = E("j")
l = F("l")
f = G("f")
i = H("i")
k = I("k")
m = J("m")

d.o = i
d.p = i
d.q = j
d.z = j
d.x = k
d.r = l
a.o = n
a.z = d
a.y = d
a.w = k
a.u = k
a.x = k
a.v = j
a.s = i
a.p = e
e.x = l
e.q = d
e.y = j
e.w = f
e.u = m
e.p = m
n.p = m
n.s = i
n.t = i
n.y = f
n.q = d
j.y = e
l.t = n
l.r = n
l.w = m
l.q = m
l.y = k
l.x = e
l.z = e
l.u = d
l.v = f
f.r = j
f.o = e
f.v = l
f.w = n
f.z = n
f.u = n
i.y = l
i.t = l
i.v = d
i.u = d
i.z = e
i.s = a
i.r = a
i.o = a
i.q = j
i.w = n
k.z = d
k.x = d
k.r = e
k.t = n
k.s = a
k.q = a
k.p = j
k.u = l
k.v = l
m.z = l
m.s = l
m.u = e
m.o = k
m.r = k
m.p = i
m.v = a
assert j.y.y.y.y.y.x.y.z.x.txt == "
class A:
    def __init__(self, txt: str):
        self.o: H = None
        self.p: H = None
        self.q: E = None
        self.x: I = None
        self.z: E = None
        self.r: F = None
        self.txt = txt

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

class C:
    def __init__(self, txt: str):
        self.x: F = None
        self.q: A = None
        self.y: E = None
        self.w: G = None
        self.u: J = None
        self.p: J = None
        self.txt = txt

class D:
    def __init__(self, txt: str):
        self.p: J = None
        self.s: H = None
        self.y: G = None
        self.t: H = None
        self.q: A = None
        self.txt = txt

class E:
    def __init__(self, txt: str):
        self.y: C = None
        self.txt = txt

class F:
    def __init__(self, txt: str):
        self.t: D = None
        self.w: J = None
        self.y: I = None
        self.x: C = None
        self.u: A = None
        self.r: D = None
        self.q: J = None
        self.z: C = None
        self.v: G = None
        self.txt = txt

class G:
    def __init__(self, txt: str):
        self.r: E = None
        self.o: C = None
        self.v: F = None
        self.w: D = None
        self.z: D = None
        self.u: D = None
        self.txt = txt

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

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

class J:
    def __init__(self, txt: str):
        self.z: F = None
        self.u: C = None
        self.o: I = None
        self.p: H = None
        self.s: F = None
        self.v: B = None
        self.r: I = None
        self.txt = txt

d = A("d")
a = B("a")
e = C("e")
n = D("n")
j = E("j")
l = F("l")
f = G("f")
i = H("i")
k = I("k")
m = J("m")

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