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

class B:
    def __init__(self, txt: str):
        self.o: C = None
        self.s: A = None
        self.v: E = None
        self.z: D = None
        self.txt = txt

class C:
    def __init__(self, txt: str):
        self.z: F = None
        self.t: F = None
        self.y: F = None
        self.w: A = None
        self.s: B = None
        self.txt = txt

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

class E:
    def __init__(self, txt: str):
        self.s: B = None
        self.q: B = None
        self.u: C = None
        self.v: A = None
        self.txt = txt

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

e = A("e")
l = B("l")
m = C("m")
i = D("i")
n = E("n")
k = F("k")
d = A("d")

e.w = i
e.z = i
e.o = d
e.u = n
l.o = m
l.s = e
l.v = n
l.z = i
m.z = k
m.t = k
m.y = k
m.w = d
m.s = l
i.r = e
i.o = e
i.q = d
i.p = d
i.y = n
i.t = l
n.s = l
n.q = l
n.u = m
n.v = d
k.t = i
k.v = i
k.o = m
d.w = i
d.z = i
d.o = e
d.u = n
assert l.z.p.u.s.z.o.txt == "
class A:
    def __init__(self, txt: str):
        self.w: D = None
        self.o: A = None
        self.z: D = None
        self.u: E = None
        self.txt = txt

class B:
    def __init__(self, txt: str):
        self.o: C = None
        self.s: A = None
        self.v: E = None
        self.z: D = None
        self.txt = txt

class C:
    def __init__(self, txt: str):
        self.z: F = None
        self.t: F = None
        self.y: F = None
        self.w: A = None
        self.s: B = None
        self.txt = txt

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

class E:
    def __init__(self, txt: str):
        self.s: B = None
        self.q: B = None
        self.u: C = None
        self.v: A = None
        self.txt = txt

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

e = A("e")
l = B("l")
m = C("m")
i = D("i")
n = E("n")
k = F("k")
d = A("d")

e.w = i
e.z = i
e.o = d
e.u = n
l.o = m
l.s = e
l.v = n
l.z = i
m.z = k
m.t = k
m.y = k
m.w = d
m.s = l
i.r = e
i.o = e
i.q = d
i.p = d
i.y = n
i.t = l
n.s = l
n.q = l
n.u = m
n.v = d
k.t = i
k.v = i
k.o = m
d.w = i
d.z = i
d.o = e
d.u = n
assert l.z.p.u.s.z.o.txt == "e"