#include <bits/stdc++.h>
using namespace std;
const long long MOD = 1e9 + 7;
const long long INF = 1e17;
int main(void) {
  long long N;
  cin >> N;
  vector<long long> A(N, 0);
  for (long long i = 0; i < N; i++) {
    cin >> A[i];
  }
  sort(A.begin(), A.end());
  for (long long i = 0; i < N; i++) {
    for (long long j = i + 1; j < N; j++) {
      vector<long long> numbers(N + 2, 0);
      numbers[0] = A[i];
      numbers[1] = A[j];
      for (long long k = 2; k < N + 2; k++) {
        numbers[k] = numbers[k - 1] ^ numbers[k - 2];
      }
      if (numbers[0] == numbers[N] && numbers[1] == numbers[N + 1]) {
        numbers.erase(numbers.begin() + N);
        numbers.erase(numbers.begin() + N);
        sort(numbers.begin(), numbers.end());
        if (numbers == A) {
          cout << "Yes" << endl;
          return 0;
        }
      }
    }
  }
  cout << "No" << endl;
  return 0;
}
