Feedback from user josemoralesp
I have this methos:
def checkio(data):
#replace this for solution
mod = (0 if len(data) % 2 else 1) + 1
half = (len(data) - 1) / 2
return sum(sorted(data)[half:half + mod]) / float(mod)
Your system raise me this error:
TypeError: slice indices must be integers or None or have an __index__ method, checkio, 6
My method is perfect, I test it in others enviroments and run correctly