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

class B:
    def __init__(self, txt: str):
        self.w: E = None
        self.y: H = None
        self.txt = txt

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

class D:
    def __init__(self, txt: str):
        self.r: F = None
        self.s: H = None
        self.x: H = None
        self.z: E = None
        self.u: B = None
        self.txt = txt

class E:
    def __init__(self, txt: str):
        self.x: C = None
        self.s: D = None
        self.txt = txt

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

class G:
    def __init__(self, txt: str):
        self.o: B = None
        self.z: H = None
        self.t: D = None
        self.p: H = None
        self.y: I = None
        self.txt = txt

class H:
    def __init__(self, txt: str):
        self.y: I = None
        self.q: I = None
        self.z: B = None
        self.t: D = None
        self.r: F = None
        self.txt = txt

class I:
    def __init__(self, txt: str):
        self.r: J = None
        self.s: A = None
        self.v: B = None
        self.o: D = None
        self.txt = txt

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

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

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

class B:
    def __init__(self, txt: str):
        self.w: E = None
        self.y: H = None
        self.txt = txt

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

class D:
    def __init__(self, txt: str):
        self.r: F = None
        self.s: H = None
        self.x: H = None
        self.z: E = None
        self.u: B = None
        self.txt = txt

class E:
    def __init__(self, txt: str):
        self.x: C = None
        self.s: D = None
        self.txt = txt

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

class G:
    def __init__(self, txt: str):
        self.o: B = None
        self.z: H = None
        self.t: D = None
        self.p: H = None
        self.y: I = None
        self.txt = txt

class H:
    def __init__(self, txt: str):
        self.y: I = None
        self.q: I = None
        self.z: B = None
        self.t: D = None
        self.r: F = None
        self.txt = txt

class I:
    def __init__(self, txt: str):
        self.r: J = None
        self.s: A = None
        self.v: B = None
        self.o: D = None
        self.txt = txt

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

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

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