import sys input = sys.stdin.readline N = int(input()) A = list(map(int, input().split())) s = sum(A) print("Yes" if s % N == 0 and len(set(map(lambda x: x % N, A))) == 1 else "No")