+ 1

2 test cases are showing to be incorrect need some help

From data science course, average of rows project: import numpy as np n, p = [int(x) for x in input().split()] elements=np.array([]) elements=elements.reshape((0,p)) for i in range(n): a=[float(x) for x in input().split(" ")] a = np.array(a) a = a.reshape(1,p) elements = np.vstack((elements,a)) print(elements.mean(axis=1))

23rd Jul 2021, 4:21 PM
shahul hameed
shahul hameed - avatar
1 ответ
+ 6
Can try with round off Based on the problem, you have to round the mean array to 2 decimal places.
23rd Jul 2021, 5:02 PM
Aditya
Aditya - avatar