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

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

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

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

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

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

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

class H:
    def __init__(self, txt: str):
        self.v: B = None
        self.txt = txt

class I:
    def __init__(self, txt: str):
        self.r: D = None
        self.t: D = None
        self.txt = txt

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

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

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

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

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

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

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

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

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

class H:
    def __init__(self, txt: str):
        self.v: B = None
        self.txt = txt

class I:
    def __init__(self, txt: str):
        self.r: D = None
        self.t: D = None
        self.txt = txt

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

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

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