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

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

class C:
    def __init__(self, txt: str):
        self.z: G = None
        self.r: A = None
        self.o: E = None
        self.p: G = None
        self.txt = txt

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

class E:
    def __init__(self, txt: str):
        self.z: D = None
        self.o: D = None
        self.s: G = None
        self.v: I = None
        self.u: B = None
        self.y: G = None
        self.q: I = None
        self.p: C = None
        self.txt = txt

class F:
    def __init__(self, txt: str):
        self.v: C = None
        self.p: C = None
        self.txt = txt

class G:
    def __init__(self, txt: str):
        self.q: J = None
        self.x: I = None
        self.r: F = None
        self.o: E = None
        self.y: H = None
        self.s: E = None
        self.txt = txt

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

class I:
    def __init__(self, txt: str):
        self.w: F = None
        self.z: G = None
        self.t: H = None
        self.y: H = None
        self.u: H = None
        self.txt = txt

class J:
    def __init__(self, txt: str):
        self.s: I = None
        self.y: I = None
        self.o: D = None
        self.x: D = None
        self.w: B = None
        self.txt = txt

e = A("e")
a = B("a")
m = C("m")
h = D("h")
f = E("f")
n = F("n")
d = G("d")
c = H("c")
j = I("j")
l = J("l")

e.s = l
e.p = l
e.u = d
a.s = j
a.w = n
m.z = d
m.p = d
m.r = e
m.o = f
h.s = j
h.u = j
h.z = a
h.o = n
h.x = n
h.q = n
h.r = c
h.w = l
h.p = d
h.y = f
f.z = h
f.o = h
f.s = d
f.y = d
f.v = j
f.q = j
f.u = a
f.p = m
n.v = m
n.p = m
d.q = l
d.x = j
d.r = n
d.o = f
d.s = f
d.y = c
c.o = e
j.w = n
j.z = d
j.t = c
j.y = c
j.u = c
l.s = j
l.y = j
l.o = h
l.x = h
l.w = a
assert h.r.o.u.r.p.r.txt == "
class A:
    def __init__(self, txt: str):
        self.s: J = None
        self.p: J = None
        self.u: G = None
        self.txt = txt

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

class C:
    def __init__(self, txt: str):
        self.z: G = None
        self.r: A = None
        self.o: E = None
        self.p: G = None
        self.txt = txt

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

class E:
    def __init__(self, txt: str):
        self.z: D = None
        self.o: D = None
        self.s: G = None
        self.v: I = None
        self.u: B = None
        self.y: G = None
        self.q: I = None
        self.p: C = None
        self.txt = txt

class F:
    def __init__(self, txt: str):
        self.v: C = None
        self.p: C = None
        self.txt = txt

class G:
    def __init__(self, txt: str):
        self.q: J = None
        self.x: I = None
        self.r: F = None
        self.o: E = None
        self.y: H = None
        self.s: E = None
        self.txt = txt

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

class I:
    def __init__(self, txt: str):
        self.w: F = None
        self.z: G = None
        self.t: H = None
        self.y: H = None
        self.u: H = None
        self.txt = txt

class J:
    def __init__(self, txt: str):
        self.s: I = None
        self.y: I = None
        self.o: D = None
        self.x: D = None
        self.w: B = None
        self.txt = txt

e = A("e")
a = B("a")
m = C("m")
h = D("h")
f = E("f")
n = F("n")
d = G("d")
c = H("c")
j = I("j")
l = J("l")

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