N=int(input()) if N==1: print(101) exit() A=list(map(int,input().split())) ans=0 for x in range(101): if (sum(A)+x)%N==0: ans+=1 print(ans)