Enable Javascript in your browser and then refresh this page, for a much enhanced experience.
First solution in Clear category for Median by bajibaji
def checkio(data: list[int]) -> int | float:
count=len(data)
data.sort()
med= int((count)/2)
if count%2==0:
return (data[med-1]+data[med])/2
else:
return data[med]
Sept. 22, 2024