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

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

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

class D:
    def __init__(self, txt: str):
        self.s: F = None
        self.o: G = None
        self.v: H = None
        self.w: B = None
        self.z: F = None
        self.txt = txt

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

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

class G:
    def __init__(self, txt: str):
        self.x: D = None
        self.t: J = None
        self.txt = txt

class H:
    def __init__(self, txt: str):
        self.o: C = None
        self.v: J = None
        self.z: G = None
        self.txt = txt

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

class J:
    def __init__(self, txt: str):
        self.u: G = None
        self.w: C = None
        self.o: A = None
        self.t: G = None
        self.txt = txt

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

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

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

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

class D:
    def __init__(self, txt: str):
        self.s: F = None
        self.o: G = None
        self.v: H = None
        self.w: B = None
        self.z: F = None
        self.txt = txt

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

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

class G:
    def __init__(self, txt: str):
        self.x: D = None
        self.t: J = None
        self.txt = txt

class H:
    def __init__(self, txt: str):
        self.o: C = None
        self.v: J = None
        self.z: G = None
        self.txt = txt

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

class J:
    def __init__(self, txt: str):
        self.u: G = None
        self.w: C = None
        self.o: A = None
        self.t: G = None
        self.txt = txt

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

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