#include <bits/stdc++.h>
using namespace std;
const double EPS = 1e-9;
template <class T, class C>
void chmax(T& a, C b) {
  a > b ?: a = b;
}
template <class T, class C>
void chmin(T& a, C b) {
  a < b ?: a = b;
}
int main() {
  cin.tie(0);
  ios::sync_with_stdio(false);
  long long n, sum1 = 0, sum2 = 0;
  cin >> n;
  long long a[n];
  for (int i = 0; i < n; i++) {
    cin >> a[i];
  }
  for (int i = 0; i < n; i++) {
    for (int j = 0; j < n; j++) {
      for (int k = 0; k < n; k++) {
        if (a[i] ^ a[j] == a[k]) {
          sum1++;
        }
      }
    }
  }
  if ((sum1 + sum2) % 2 == 0 && sum1 == sum2) {
    cout << "Yes" << endl;
  } else {
    cout << "No" << endl;
  }
}
