class A:
    def __init__(self, txt: str):
        self.v: F = None
        self.z: I = None
        self.w: H = None
        self.o: C = None
        self.r: I = None
        self.x: H = None
        self.q: E = None
        self.txt = txt

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

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

class D:
    def __init__(self, txt: str):
        self.z: F = None
        self.txt = txt

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

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

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

class H:
    def __init__(self, txt: str):
        self.o: E = None
        self.s: A = None
        self.u: A = None
        self.z: I = None
        self.r: G = None
        self.txt = txt

class I:
    def __init__(self, txt: str):
        self.y: J = None
        self.t: H = None
        self.w: F = None
        self.r: H = None
        self.s: F = None
        self.x: F = None
        self.u: B = None
        self.q: E = None
        self.txt = txt

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

b = A("b")
f = B("f")
d = C("d")
e = D("e")
g = E("g")
h = F("h")
n = G("n")
k = H("k")
m = I("m")
l = J("l")

b.v = h
b.z = m
b.r = m
b.w = k
b.x = k
b.o = d
b.q = g
f.v = b
d.o = e
d.x = e
d.z = h
d.v = h
d.p = h
d.y = b
d.u = b
d.s = g
e.z = h
g.x = n
g.r = b
g.w = b
g.p = e
g.v = d
g.o = l
g.y = l
g.z = k
g.s = m
g.u = f
h.o = m
h.v = n
h.p = n
h.u = g
h.w = l
h.z = f
n.r = e
n.y = k
n.v = k
n.u = k
n.z = f
n.w = f
n.q = h
n.t = d
n.s = d
n.p = b
k.o = g
k.s = b
k.u = b
k.z = m
k.r = n
m.y = l
m.t = k
m.r = k
m.w = h
m.s = h
m.x = h
m.u = f
m.q = g
l.u = b
l.y = e
l.s = e
l.p = m
l.o = m
l.z = f
l.x = f
l.t = g
l.v = k
l.w = h
assert l.p.s.z.v.x.z.txt == "
class A:
    def __init__(self, txt: str):
        self.v: F = None
        self.z: I = None
        self.w: H = None
        self.o: C = None
        self.r: I = None
        self.x: H = None
        self.q: E = None
        self.txt = txt

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

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

class D:
    def __init__(self, txt: str):
        self.z: F = None
        self.txt = txt

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

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

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

class H:
    def __init__(self, txt: str):
        self.o: E = None
        self.s: A = None
        self.u: A = None
        self.z: I = None
        self.r: G = None
        self.txt = txt

class I:
    def __init__(self, txt: str):
        self.y: J = None
        self.t: H = None
        self.w: F = None
        self.r: H = None
        self.s: F = None
        self.x: F = None
        self.u: B = None
        self.q: E = None
        self.txt = txt

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

b = A("b")
f = B("f")
d = C("d")
e = D("e")
g = E("g")
h = F("h")
n = G("n")
k = H("k")
m = I("m")
l = J("l")

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