class A:
    def __init__(self, txt: str):
        self.s: J = None
        self.v: H = None
        self.q: J = None
        self.txt = txt

class B:
    def __init__(self, txt: str):
        self.x: I = None
        self.s: G = None
        self.t: H = None
        self.txt = txt

class C:
    def __init__(self, txt: str):
        self.p: A = None
        self.x: F = None
        self.txt = txt

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

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

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

class G:
    def __init__(self, txt: str):
        self.t: D = None
        self.z: J = None
        self.u: H = None
        self.v: C = None
        self.p: B = None
        self.txt = txt

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

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

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

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

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

class B:
    def __init__(self, txt: str):
        self.x: I = None
        self.s: G = None
        self.t: H = None
        self.txt = txt

class C:
    def __init__(self, txt: str):
        self.p: A = None
        self.x: F = None
        self.txt = txt

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

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

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

class G:
    def __init__(self, txt: str):
        self.t: D = None
        self.z: J = None
        self.u: H = None
        self.v: C = None
        self.p: B = None
        self.txt = txt

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

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

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

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

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