N = int(input()) A = list(map(int,input().split())) S = sum(A) ans = 0 for i in range(101): total = N*i if 0 <= total - S <= 100: ans += 1 print(ans)