class A:
    def __init__(self, txt: str):
        self.q: A = None
        self.v: A = None
        self.p: E = None
        self.w: E = None
        self.s: A = None
        self.txt = txt

class B:
    def __init__(self, txt: str):
        self.s: D = None
        self.v: D = None
        self.y: C = None
        self.t: B = None
        self.u: B = None
        self.txt = txt

class C:
    def __init__(self, txt: str):
        self.r: D = None
        self.p: A = None
        self.q: B = None
        self.y: E = None
        self.txt = txt

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

class E:
    def __init__(self, txt: str):
        self.w: A = None
        self.u: A = None
        self.r: D = None
        self.q: D = None
        self.x: D = None
        self.txt = txt

g = A("g")
i = B("i")
f = C("f")
a = D("a")
h = E("h")
l = B("l")
n = E("n")
k = A("k")
e = A("e")

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

class B:
    def __init__(self, txt: str):
        self.s: D = None
        self.v: D = None
        self.y: C = None
        self.t: B = None
        self.u: B = None
        self.txt = txt

class C:
    def __init__(self, txt: str):
        self.r: D = None
        self.p: A = None
        self.q: B = None
        self.y: E = None
        self.txt = txt

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

class E:
    def __init__(self, txt: str):
        self.w: A = None
        self.u: A = None
        self.r: D = None
        self.q: D = None
        self.x: D = None
        self.txt = txt

g = A("g")
i = B("i")
f = C("f")
a = D("a")
h = E("h")
l = B("l")
n = E("n")
k = A("k")
e = A("e")

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