N = int(input()) A = list(map(int, input().split())) now = 0 for a in A: now ^= a if now != 0: print('No') exit() if N > 5000: print('Yes') exit() dp = [0] * 8192 dp[0] = 1 for a in A: ndp = dp[:] for i in range(8192): ndp[i ^ a] += dp[i] dp = ndp[:] if dp[0] >= 3: print('Yes') else: print('No')