whats wrong with this code in python 3.1.2…for the problem “the little elephants and candies”?
import sys
t=int(input())
for i in range(t):
n,c=map(int,sys.stdin.readline().split())
a=list(map(int,sys.stdin.readline().split()))
if c>=sum(a):
print("yes")
else:
print("no")