class A:
    def __init__(self, txt: str):
        self.r: I = None
        self.u: J = None
        self.txt = txt

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

class C:
    def __init__(self, txt: str):
        self.r: G = None
        self.q: B = None
        self.txt = txt

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

class E:
    def __init__(self, txt: str):
        self.o: I = None
        self.q: J = None
        self.v: I = None
        self.x: G = None
        self.p: I = None
        self.s: D = None
        self.u: I = None
        self.txt = txt

class F:
    def __init__(self, txt: str):
        self.x: G = None
        self.z: J = None
        self.s: E = None
        self.q: B = None
        self.u: D = None
        self.txt = txt

class G:
    def __init__(self, txt: str):
        self.v: A = None
        self.w: F = None
        self.q: I = None
        self.z: J = None
        self.t: I = None
        self.p: B = None
        self.o: B = None
        self.txt = txt

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

class I:
    def __init__(self, txt: str):
        self.v: D = None
        self.o: F = None
        self.p: A = None
        self.z: F = None
        self.q: F = None
        self.t: D = None
        self.r: J = None
        self.txt = txt

class J:
    def __init__(self, txt: str):
        self.q: F = None
        self.u: B = None
        self.txt = txt

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

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

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

class C:
    def __init__(self, txt: str):
        self.r: G = None
        self.q: B = None
        self.txt = txt

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

class E:
    def __init__(self, txt: str):
        self.o: I = None
        self.q: J = None
        self.v: I = None
        self.x: G = None
        self.p: I = None
        self.s: D = None
        self.u: I = None
        self.txt = txt

class F:
    def __init__(self, txt: str):
        self.x: G = None
        self.z: J = None
        self.s: E = None
        self.q: B = None
        self.u: D = None
        self.txt = txt

class G:
    def __init__(self, txt: str):
        self.v: A = None
        self.w: F = None
        self.q: I = None
        self.z: J = None
        self.t: I = None
        self.p: B = None
        self.o: B = None
        self.txt = txt

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

class I:
    def __init__(self, txt: str):
        self.v: D = None
        self.o: F = None
        self.p: A = None
        self.z: F = None
        self.q: F = None
        self.t: D = None
        self.r: J = None
        self.txt = txt

class J:
    def __init__(self, txt: str):
        self.q: F = None
        self.u: B = None
        self.txt = txt

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

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