finding mean in python code example
Example 1: how to calculate mean in python
import statistics
a = [1,2,3,4,5]
mean = statistics.mean(a)
#Similar for other values such as variance, standard deviation
Example 2: calculate mean on python
def calculate_mean(n):
s = sum(n)
N = len(n)
mean = s / N
return mean