You are viewing a single comment's thread. Return to all comments →
import numpy as np
N,M = list(map(int, input().split())) ll=[] for i in range(N): arr=np.array(list(map(int, input().split()))) ll.append(arr) print(np.mean(ll, axis = 1)) print(np.var(ll, axis = 0)) print(np.round(np.std(ll),11))
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 = list(map(int, input().split())) ll=[] for i in range(N): arr=np.array(list(map(int, input().split()))) ll.append(arr) print(np.mean(ll, axis = 1)) print(np.var(ll, axis = 0)) print(np.round(np.std(ll),11))