You are viewing a single comment's thread. Return to all comments →
import numpy as np
n, m = map(int, input().split())
ar = np.array([list(map(int, input().split())) for i in range(n)])
print(np.mean(ar, axis = 1)) print(np.var(ar, axis = 0)) print(round(np.std(ar), 11)) # 11 significant figures to match the expected result format
Seems like cookies are disabled on this browser, please enable them to open this website
Mean, Var, and Std
You are viewing a single comment's thread. Return to all comments →
import numpy as np
n, m = map(int, input().split())
ar = np.array([list(map(int, input().split())) for i in range(n)])
print(np.mean(ar, axis = 1)) print(np.var(ar, axis = 0)) print(round(np.std(ar), 11)) # 11 significant figures to match the expected result format