It says median[1] returns 0 instead of 1. Here is my code:

```
def median(_list):
_list.sort()
if len(_list) % 2 == 0:
n = len(_list) / 2
m = n - 1
mid = (_list[n] + _list[m]) / 2
else:
n = len(_list) / 2
mid = (_list[n]) / 2
return mid
```

Please help me.