n=int(input()) a=list(map(int,input().split())) sum_a=0 for x in a:sum_a+=x ans=0 for i in range(101): if (sum_a+i)%n==0: ans+=1 print(ans)