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

class B:
    def __init__(self, txt: str):
        self.x: D = None
        self.y: J = None
        self.z: C = None
        self.w: I = None
        self.txt = txt

class C:
    def __init__(self, txt: str):
        self.z: I = None
        self.p: B = None
        self.q: F = None
        self.t: J = None
        self.txt = txt

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

class E:
    def __init__(self, txt: str):
        self.o: G = None
        self.x: I = None
        self.v: G = None
        self.txt = txt

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

class G:
    def __init__(self, txt: str):
        self.s: J = None
        self.txt = txt

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

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

class J:
    def __init__(self, txt: str):
        self.s: D = None
        self.txt = txt

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

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

class B:
    def __init__(self, txt: str):
        self.x: D = None
        self.y: J = None
        self.z: C = None
        self.w: I = None
        self.txt = txt

class C:
    def __init__(self, txt: str):
        self.z: I = None
        self.p: B = None
        self.q: F = None
        self.t: J = None
        self.txt = txt

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

class E:
    def __init__(self, txt: str):
        self.o: G = None
        self.x: I = None
        self.v: G = None
        self.txt = txt

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

class G:
    def __init__(self, txt: str):
        self.s: J = None
        self.txt = txt

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

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

class J:
    def __init__(self, txt: str):
        self.s: D = None
        self.txt = txt

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

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