class A:
    def __init__(self, txt: str):
        self.s: B = None
        self.txt = txt

class B:
    def __init__(self, txt: str):
        self.z: G = None
        self.r: J = None
        self.p: D = None
        self.x: C = None
        self.y: G = None
        self.q: J = None
        self.txt = txt

class C:
    def __init__(self, txt: str):
        self.q: J = None
        self.z: G = None
        self.u: E = None
        self.txt = txt

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

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

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

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

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

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

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

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

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

class B:
    def __init__(self, txt: str):
        self.z: G = None
        self.r: J = None
        self.p: D = None
        self.x: C = None
        self.y: G = None
        self.q: J = None
        self.txt = txt

class C:
    def __init__(self, txt: str):
        self.q: J = None
        self.z: G = None
        self.u: E = None
        self.txt = txt

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

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

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

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

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

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

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

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

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