15. median. (SOLVED) Please Help, don't know where to start (SOLVED)



I'm stuck on question 15 as I dont even know where to start. Please you you give me some hints?

def median(lst):


How would you find the median by hand?


No, I want to do it in code!


Coding is giving the computer instructions. How are you going to do that if you don't know how to find the median yourself?
Just list out a step by step process on how to find the median. Then translate that into code.


Ummm.... okay, I know how to find the median by hand, just not in code.


Ok, so what's the first step to finding the median?


import numpy
def median(lst):
return numpy.median(numpy.array(lst))


Hmm yes using a module is helpful. Out of scope considering the lessons but good job.


This topic was automatically closed 7 days after the last reply. New replies are no longer allowed.