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

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

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

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

class E:
    def __init__(self, txt: str):
        self.r: F = None
        self.q: D = None
        self.z: C = None
        self.x: G = None
        self.p: I = None
        self.txt = txt

class F:
    def __init__(self, txt: str):
        self.q: H = None
        self.v: B = None
        self.z: B = None
        self.txt = txt

class G:
    def __init__(self, txt: str):
        self.z: F = None
        self.u: A = None
        self.p: H = None
        self.txt = txt

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

class I:
    def __init__(self, txt: str):
        self.t: C = None
        self.txt = txt

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

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

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

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

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

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

class E:
    def __init__(self, txt: str):
        self.r: F = None
        self.q: D = None
        self.z: C = None
        self.x: G = None
        self.p: I = None
        self.txt = txt

class F:
    def __init__(self, txt: str):
        self.q: H = None
        self.v: B = None
        self.z: B = None
        self.txt = txt

class G:
    def __init__(self, txt: str):
        self.z: F = None
        self.u: A = None
        self.p: H = None
        self.txt = txt

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

class I:
    def __init__(self, txt: str):
        self.t: C = None
        self.txt = txt

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

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

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