Hello, can someone plz tell me what's wrong with my code because this code works fine on other IDEs. it's gives me the error below when i run it on codecademy.
Oops, try again. median([4, 5, 5, 4]) returned 4 instead of 4.5
def median(li): li=sorted(li) look=len(li) if look%2 != 0: life=look/2 life=life+0.5 life=life-1 life=int(life) return li[life] else: life=look/2 lo=life-1 lo=int(lo) life=int(life) lok=li[life] + li[lo] lok=lok/2 return lok