N = int(input()) A = list(map(int, input().split())) B = set([A[i] % N for i in range(N)]) if len(B) == 1: print("Yes") else: print("No")