class A:
    def __init__(self, txt: str):
        self.x: J = None
        self.txt = txt

class B:
    def __init__(self, txt: str):
        self.v: A = None
        self.q: D = None
        self.x: F = None
        self.w: J = None
        self.r: G = None
        self.t: H = None
        self.txt = txt

class C:
    def __init__(self, txt: str):
        self.x: H = None
        self.y: J = None
        self.q: A = None
        self.p: I = None
        self.txt = txt

class D:
    def __init__(self, txt: str):
        self.p: H = None
        self.s: C = None
        self.v: B = None
        self.q: G = None
        self.txt = txt

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

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

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

class H:
    def __init__(self, txt: str):
        self.y: C = None
        self.z: I = None
        self.x: B = None
        self.w: B = None
        self.r: I = None
        self.s: E = None
        self.txt = txt

class I:
    def __init__(self, txt: str):
        self.u: F = None
        self.y: J = None
        self.o: D = None
        self.x: H = None
        self.z: J = None
        self.s: J = None
        self.txt = txt

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

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

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

class B:
    def __init__(self, txt: str):
        self.v: A = None
        self.q: D = None
        self.x: F = None
        self.w: J = None
        self.r: G = None
        self.t: H = None
        self.txt = txt

class C:
    def __init__(self, txt: str):
        self.x: H = None
        self.y: J = None
        self.q: A = None
        self.p: I = None
        self.txt = txt

class D:
    def __init__(self, txt: str):
        self.p: H = None
        self.s: C = None
        self.v: B = None
        self.q: G = None
        self.txt = txt

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

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

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

class H:
    def __init__(self, txt: str):
        self.y: C = None
        self.z: I = None
        self.x: B = None
        self.w: B = None
        self.r: I = None
        self.s: E = None
        self.txt = txt

class I:
    def __init__(self, txt: str):
        self.u: F = None
        self.y: J = None
        self.o: D = None
        self.x: H = None
        self.z: J = None
        self.s: J = None
        self.txt = txt

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

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

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