0

So basically i have to write a python script of display standard deviation to a given list of numbers

l=[] s=0 n=eval(input("Enter maximum number of values : ")) for i in range(1,n+1): l.append(int(input("Enter value :" ))) mean=sum(l)/n for val in l: x=(val-mean)**2 s+=x print("sd="(s/(n-1))**0.5) BUT THIS CODE IS GIVING AN ERROR.

1st Sep 2019, 4:35 PM
Yash Kumar
Yash Kumar - avatar
1 Respuesta
+ 4
You're missing a comma: print("sd=", (... and so on
1st Sep 2019, 4:49 PM
HonFu
HonFu - avatar