class A:
    def __init__(self, txt: str):
        self.v: C = None
        self.o: G = None
        self.t: C = None
        self.txt = txt

class B:
    def __init__(self, txt: str):
        self.z: J = None
        self.x: F = None
        self.txt = txt

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

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

class E:
    def __init__(self, txt: str):
        self.q: C = None
        self.z: F = None
        self.v: A = None
        self.p: I = None
        self.txt = txt

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

class G:
    def __init__(self, txt: str):
        self.x: I = None
        self.t: A = None
        self.u: F = None
        self.v: I = None
        self.txt = txt

class H:
    def __init__(self, txt: str):
        self.z: I = None
        self.y: E = None
        self.r: F = None
        self.txt = txt

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

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

m = A("m")
f = B("f")
k = C("k")
h = D("h")
g = E("g")
c = F("c")
d = G("d")
e = H("e")
j = I("j")
a = J("a")

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

class B:
    def __init__(self, txt: str):
        self.z: J = None
        self.x: F = None
        self.txt = txt

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

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

class E:
    def __init__(self, txt: str):
        self.q: C = None
        self.z: F = None
        self.v: A = None
        self.p: I = None
        self.txt = txt

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

class G:
    def __init__(self, txt: str):
        self.x: I = None
        self.t: A = None
        self.u: F = None
        self.v: I = None
        self.txt = txt

class H:
    def __init__(self, txt: str):
        self.z: I = None
        self.y: E = None
        self.r: F = None
        self.txt = txt

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

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

m = A("m")
f = B("f")
k = C("k")
h = D("h")
g = E("g")
c = F("c")
d = G("d")
e = H("e")
j = I("j")
a = J("a")

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