class A:
    def __init__(self, txt: str):
        self.y: H = None
        self.o: D = None
        self.x: B = None
        self.txt = txt

class B:
    def __init__(self, txt: str):
        self.x: D = None
        self.txt = txt

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

class D:
    def __init__(self, txt: str):
        self.y: G = None
        self.z: J = None
        self.t: C = None
        self.s: A = None
        self.v: C = None
        self.w: A = None
        self.r: E = None
        self.txt = txt

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

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

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

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

class I:
    def __init__(self, txt: str):
        self.o: F = None
        self.y: D = None
        self.txt = txt

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

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

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

class B:
    def __init__(self, txt: str):
        self.x: D = None
        self.txt = txt

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

class D:
    def __init__(self, txt: str):
        self.y: G = None
        self.z: J = None
        self.t: C = None
        self.s: A = None
        self.v: C = None
        self.w: A = None
        self.r: E = None
        self.txt = txt

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

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

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

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

class I:
    def __init__(self, txt: str):
        self.o: F = None
        self.y: D = None
        self.txt = txt

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

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

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