class A:
    def __init__(self, txt: str):
        self.s: I = None
        self.y: H = None
        self.x: H = None
        self.u: I = None
        self.o: I = None
        self.r: E = None
        self.v: B = None
        self.txt = txt

class B:
    def __init__(self, txt: str):
        self.w: G = None
        self.v: H = None
        self.s: F = None
        self.txt = txt

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

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

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

class F:
    def __init__(self, txt: str):
        self.z: H = None
        self.o: H = None
        self.u: B = None
        self.x: D = None
        self.t: I = None
        self.s: D = None
        self.w: B = None
        self.txt = txt

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

class H:
    def __init__(self, txt: str):
        self.s: E = None
        self.w: B = None
        self.u: G = None
        self.r: E = None
        self.txt = txt

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

class J:
    def __init__(self, txt: str):
        self.y: D = None
        self.t: B = None
        self.txt = txt

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

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

class B:
    def __init__(self, txt: str):
        self.w: G = None
        self.v: H = None
        self.s: F = None
        self.txt = txt

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

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

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

class F:
    def __init__(self, txt: str):
        self.z: H = None
        self.o: H = None
        self.u: B = None
        self.x: D = None
        self.t: I = None
        self.s: D = None
        self.w: B = None
        self.txt = txt

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

class H:
    def __init__(self, txt: str):
        self.s: E = None
        self.w: B = None
        self.u: G = None
        self.r: E = None
        self.txt = txt

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

class J:
    def __init__(self, txt: str):
        self.y: D = None
        self.t: B = None
        self.txt = txt

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

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