class A:
    def __init__(self, txt: str):
        self.p: E = None
        self.q: J = None
        self.o: H = None
        self.txt = txt

class B:
    def __init__(self, txt: str):
        self.y: J = None
        self.w: F = None
        self.z: E = None
        self.v: G = None
        self.o: G = None
        self.q: F = None
        self.txt = txt

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

class D:
    def __init__(self, txt: str):
        self.w: E = None
        self.v: A = None
        self.y: H = None
        self.z: H = None
        self.o: I = None
        self.u: I = None
        self.txt = txt

class E:
    def __init__(self, txt: str):
        self.t: J = None
        self.u: B = None
        self.x: H = None
        self.y: D = None
        self.r: I = None
        self.txt = txt

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

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

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

class I:
    def __init__(self, txt: str):
        self.v: C = None
        self.u: A = None
        self.txt = txt

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

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

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

class B:
    def __init__(self, txt: str):
        self.y: J = None
        self.w: F = None
        self.z: E = None
        self.v: G = None
        self.o: G = None
        self.q: F = None
        self.txt = txt

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

class D:
    def __init__(self, txt: str):
        self.w: E = None
        self.v: A = None
        self.y: H = None
        self.z: H = None
        self.o: I = None
        self.u: I = None
        self.txt = txt

class E:
    def __init__(self, txt: str):
        self.t: J = None
        self.u: B = None
        self.x: H = None
        self.y: D = None
        self.r: I = None
        self.txt = txt

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

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

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

class I:
    def __init__(self, txt: str):
        self.v: C = None
        self.u: A = None
        self.txt = txt

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

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

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