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

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

class C:
    def __init__(self, txt: str):
        self.x: A = None
        self.p: E = None
        self.t: E = None
        self.o: D = None
        self.txt = txt

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

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

l = A("l")
d = B("d")
i = C("i")
h = D("h")
g = E("g")
k = D("k")
e = B("e")

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

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

class C:
    def __init__(self, txt: str):
        self.x: A = None
        self.p: E = None
        self.t: E = None
        self.o: D = None
        self.txt = txt

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

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

l = A("l")
d = B("d")
i = C("i")
h = D("h")
g = E("g")
k = D("k")
e = B("e")

l.o = d
l.r = d
l.z = g
l.p = h
d.w = i
d.v = i
d.z = i
d.u = e
d.s = l
i.x = l
i.p = g
i.t = g
i.o = h
h.o = g
h.s = l
h.v = d
g.u = l
g.s = e
g.y = k
g.r = i
k.o = g
k.s = l
k.v = e
e.w = i
e.v = i
e.z = i
e.u = d
e.s = l
assert h.o.u.z.y.v.txt == "e"