class A:
    def __init__(self, txt: str):
        self.w: D = None
        self.o: D = None
        self.y: E = None
        self.s: D = None
        self.r: C = None
        self.txt = txt

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

class C:
    def __init__(self, txt: str):
        self.z: D = None
        self.txt = txt

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

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

n = A("n")
l = B("l")
e = C("e")
h = D("h")
j = E("j")
f = D("f")

n.w = f
n.s = f
n.o = h
n.y = j
n.r = e
l.v = e
l.s = n
l.z = j
e.z = h
h.z = n
h.t = n
h.v = j
h.o = l
h.q = e
j.u = f
j.r = e
j.y = e
j.t = n
j.s = l
f.z = n
f.t = n
f.v = j
f.o = l
f.q = e
assert e.z.v.y.txt == "
class A:
    def __init__(self, txt: str):
        self.w: D = None
        self.o: D = None
        self.y: E = None
        self.s: D = None
        self.r: C = None
        self.txt = txt

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

class C:
    def __init__(self, txt: str):
        self.z: D = None
        self.txt = txt

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

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

n = A("n")
l = B("l")
e = C("e")
h = D("h")
j = E("j")
f = D("f")

n.w = f
n.s = f
n.o = h
n.y = j
n.r = e
l.v = e
l.s = n
l.z = j
e.z = h
h.z = n
h.t = n
h.v = j
h.o = l
h.q = e
j.u = f
j.r = e
j.y = e
j.t = n
j.s = l
f.z = n
f.t = n
f.v = j
f.o = l
f.q = e
assert e.z.v.y.txt == "e"