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

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

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

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

class E:
    def __init__(self, txt: str):
        self.y: J = None
        self.txt = txt

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

class G:
    def __init__(self, txt: str):
        self.w: B = None
        self.t: E = None
        self.p: I = None
        self.s: E = None
        self.txt = txt

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

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

class J:
    def __init__(self, txt: str):
        self.t: C = None
        self.s: F = None
        self.z: G = None
        self.w: H = None
        self.txt = txt

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

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

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

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

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

class E:
    def __init__(self, txt: str):
        self.y: J = None
        self.txt = txt

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

class G:
    def __init__(self, txt: str):
        self.w: B = None
        self.t: E = None
        self.p: I = None
        self.s: E = None
        self.txt = txt

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

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

class J:
    def __init__(self, txt: str):
        self.t: C = None
        self.s: F = None
        self.z: G = None
        self.w: H = None
        self.txt = txt

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

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