hi, i am submitting one problem solution but i get nzec error while submitting it…

i’ve tried input().split() and raw_input().split() but noting works. giving nzec error in line 1

here is my code::

for _ in range(int(input())):

n=int(input())

profit=0

i=1

l=list(map(int,input().split(’ ')))

l.sort(reverse=True)

profit+=l.pop(0)

for p in range(n-1):

t=l.pop(0)

if t-i<=0:

profit+=0

break

else:

profit+=(t-i)

i+=1

print(profit)