class A:
    def __init__(self, txt: str):
        self.s: I = None
        self.o: E = None
        self.q: G = None
        self.z: C = None
        self.r: E = None
        self.x: J = None
        self.u: H = None
        self.txt = txt

class B:
    def __init__(self, txt: str):
        self.r: D = None
        self.p: G = None
        self.w: A = None
        self.y: E = None
        self.t: G = None
        self.z: H = None
        self.txt = txt

class C:
    def __init__(self, txt: str):
        self.z: I = None
        self.s: F = None
        self.w: A = None
        self.x: G = None
        self.txt = txt

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

class E:
    def __init__(self, txt: str):
        self.s: G = None
        self.u: F = None
        self.w: A = None
        self.txt = txt

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

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

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

class I:
    def __init__(self, txt: str):
        self.x: C = None
        self.o: E = None
        self.p: G = None
        self.txt = txt

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

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

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

class B:
    def __init__(self, txt: str):
        self.r: D = None
        self.p: G = None
        self.w: A = None
        self.y: E = None
        self.t: G = None
        self.z: H = None
        self.txt = txt

class C:
    def __init__(self, txt: str):
        self.z: I = None
        self.s: F = None
        self.w: A = None
        self.x: G = None
        self.txt = txt

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

class E:
    def __init__(self, txt: str):
        self.s: G = None
        self.u: F = None
        self.w: A = None
        self.txt = txt

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

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

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

class I:
    def __init__(self, txt: str):
        self.x: C = None
        self.o: E = None
        self.p: G = None
        self.txt = txt

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

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

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