Answers for "mean"

-2

mean

#the plan is to have a boring mean
def mean(arr): # mean
  return sum(arr)/len(arr)
Posted by: Guest on October-12-2020
-1

mean

#the plan is to remove all values that are zero

def mean(arr): # mod_mean
  arr = list(filter(lambda n:n!=0,arr))
  return sum(arr)/len(arr)
Posted by: Guest on October-12-2020

Python Answers by Framework

Browse Popular Code Answers by Language