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

class B:
    def __init__(self, txt: str):
        self.s: G = None
        self.u: I = None
        self.p: F = None
        self.w: A = None
        self.txt = txt

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

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

class E:
    def __init__(self, txt: str):
        self.t: C = None
        self.p: F = None
        self.w: D = None
        self.z: A = None
        self.r: C = None
        self.txt = txt

class F:
    def __init__(self, txt: str):
        self.t: A = None
        self.w: E = None
        self.txt = txt

class G:
    def __init__(self, txt: str):
        self.w: I = None
        self.o: D = None
        self.s: E = None
        self.y: J = None
        self.r: H = None
        self.p: J = None
        self.t: J = None
        self.txt = txt

class H:
    def __init__(self, txt: str):
        self.q: B = None
        self.t: J = None
        self.o: C = None
        self.txt = txt

class I:
    def __init__(self, txt: str):
        self.y: F = None
        self.r: G = None
        self.o: F = None
        self.w: A = None
        self.q: G = None
        self.z: E = None
        self.t: D = None
        self.x: G = None
        self.txt = txt

class J:
    def __init__(self, txt: str):
        self.r: G = None
        self.txt = txt

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

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

class B:
    def __init__(self, txt: str):
        self.s: G = None
        self.u: I = None
        self.p: F = None
        self.w: A = None
        self.txt = txt

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

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

class E:
    def __init__(self, txt: str):
        self.t: C = None
        self.p: F = None
        self.w: D = None
        self.z: A = None
        self.r: C = None
        self.txt = txt

class F:
    def __init__(self, txt: str):
        self.t: A = None
        self.w: E = None
        self.txt = txt

class G:
    def __init__(self, txt: str):
        self.w: I = None
        self.o: D = None
        self.s: E = None
        self.y: J = None
        self.r: H = None
        self.p: J = None
        self.t: J = None
        self.txt = txt

class H:
    def __init__(self, txt: str):
        self.q: B = None
        self.t: J = None
        self.o: C = None
        self.txt = txt

class I:
    def __init__(self, txt: str):
        self.y: F = None
        self.r: G = None
        self.o: F = None
        self.w: A = None
        self.q: G = None
        self.z: E = None
        self.t: D = None
        self.x: G = None
        self.txt = txt

class J:
    def __init__(self, txt: str):
        self.r: G = None
        self.txt = txt

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

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