N = int(input()) A = list(map(int, input().split())) p, m = 0, 0 S = sum(A) if S % N != 0: print("No") exit() S //= N for a in A: if a <= S: p += S - a else: d = a - S m += d print("Yes") if p == m else print("No")