I have written code to solve a problem.
Here is My Code:
t=int(input())
print("")
while(t):
s=0
n=int(input())
for i in range(n):
no=int(input())
s=s+no
if s%n==0:
print("YES")
else:
print("NO")
print("")
t-=1
When I run it on the OS X terminal, it works fine. But when I run it on IDEone
or Submit it as a solution, it gives an error on line 5
:
ValueError: invalid literal for int() with base 10: ''
I am unsure of what the problem is.