import itertools N = int(input()) A = list(map(int, input().split())) S = 0 for a in A: S ^= a if S != 0: print("No") for X in itertools.product((True, False), repeat=N): if len(set(X)) == 1: continue t = 0 for a, x in zip(A, X): if x: t ^= a if t == 0: print("Yes") exit() print("No")