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

class B:
    def __init__(self, txt: str):
        self.q: I = None
        self.t: A = None
        self.u: I = None
        self.w: A = None
        self.v: J = None
        self.txt = txt

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

class D:
    def __init__(self, txt: str):
        self.q: H = None
        self.txt = txt

class E:
    def __init__(self, txt: str):
        self.w: G = None
        self.p: J = None
        self.txt = txt

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

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

class H:
    def __init__(self, txt: str):
        self.v: J = None
        self.w: D = None
        self.z: B = None
        self.s: B = None
        self.u: A = None
        self.txt = txt

class I:
    def __init__(self, txt: str):
        self.z: J = None
        self.p: E = None
        self.v: J = None
        self.w: H = None
        self.txt = txt

class J:
    def __init__(self, txt: str):
        self.s: H = None
        self.w: I = None
        self.txt = txt

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

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

class B:
    def __init__(self, txt: str):
        self.q: I = None
        self.t: A = None
        self.u: I = None
        self.w: A = None
        self.v: J = None
        self.txt = txt

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

class D:
    def __init__(self, txt: str):
        self.q: H = None
        self.txt = txt

class E:
    def __init__(self, txt: str):
        self.w: G = None
        self.p: J = None
        self.txt = txt

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

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

class H:
    def __init__(self, txt: str):
        self.v: J = None
        self.w: D = None
        self.z: B = None
        self.s: B = None
        self.u: A = None
        self.txt = txt

class I:
    def __init__(self, txt: str):
        self.z: J = None
        self.p: E = None
        self.v: J = None
        self.w: H = None
        self.txt = txt

class J:
    def __init__(self, txt: str):
        self.s: H = None
        self.w: I = None
        self.txt = txt

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

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