class A:
    def __init__(self, txt: str):
        self.o: C = None
        self.s: G = None
        self.txt = txt

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

class C:
    def __init__(self, txt: str):
        self.s: I = None
        self.txt = txt

class D:
    def __init__(self, txt: str):
        self.p: J = None
        self.w: B = None
        self.s: J = None
        self.x: A = None
        self.v: H = None
        self.txt = txt

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

class F:
    def __init__(self, txt: str):
        self.x: H = None
        self.u: B = None
        self.w: J = None
        self.t: E = None
        self.p: D = None
        self.txt = txt

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

class H:
    def __init__(self, txt: str):
        self.s: F = None
        self.y: G = None
        self.v: C = None
        self.p: G = None
        self.w: J = None
        self.q: F = None
        self.z: D = None
        self.u: G = None
        self.txt = txt

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

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

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

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

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

class C:
    def __init__(self, txt: str):
        self.s: I = None
        self.txt = txt

class D:
    def __init__(self, txt: str):
        self.p: J = None
        self.w: B = None
        self.s: J = None
        self.x: A = None
        self.v: H = None
        self.txt = txt

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

class F:
    def __init__(self, txt: str):
        self.x: H = None
        self.u: B = None
        self.w: J = None
        self.t: E = None
        self.p: D = None
        self.txt = txt

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

class H:
    def __init__(self, txt: str):
        self.s: F = None
        self.y: G = None
        self.v: C = None
        self.p: G = None
        self.w: J = None
        self.q: F = None
        self.z: D = None
        self.u: G = None
        self.txt = txt

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

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

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

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