mean python code

Solutions on MaxInterview for mean python code by the best coders in the world

showing results for - "mean python code"
Jacob
14 May 2019
1>>> import statistics
2
3>>> statistics.mean([4, 8, 6, 5, 3, 2, 8, 9, 2, 5])
45.2
5
Amanda
31 Jan 2019
1>>> def my_mean(sample):
2...     return sum(sample) / len(sample)
3...
4
5>>> my_mean([4, 8, 6, 5, 3, 2, 8, 9, 2, 5])
65.2
7