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

class B:
    def __init__(self, txt: str):
        self.r: C = None
        self.t: E = None
        self.v: F = None
        self.txt = txt

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

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

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

class F:
    def __init__(self, txt: str):
        self.s: B = None
        self.u: C = None
        self.x: E = None
        self.txt = txt

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

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

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

class J:
    def __init__(self, txt: str):
        self.y: G = None
        self.w: A = None
        self.z: C = None
        self.o: F = None
        self.x: H = None
        self.txt = txt

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

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

class B:
    def __init__(self, txt: str):
        self.r: C = None
        self.t: E = None
        self.v: F = None
        self.txt = txt

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

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

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

class F:
    def __init__(self, txt: str):
        self.s: B = None
        self.u: C = None
        self.x: E = None
        self.txt = txt

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

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

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

class J:
    def __init__(self, txt: str):
        self.y: G = None
        self.w: A = None
        self.z: C = None
        self.o: F = None
        self.x: H = None
        self.txt = txt

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

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