#include <bits/stdc++.h>
using namespace std;
vector<uint64_t> a;
int visited[101010];
int n;
bool dfs(int cur, int pre, int num) {
  if (num == n) {
    if ((a[0] xor a[cur] xor a[pre]) == 0)
      return true;
    else
      return false;
  }
  if (cur == 0) {
    for (int i = 1; i < n; ++i) {
      num++;
      visited[i] = 1;
      bool ans = dfs(i, cur, num);
      visited[i] = 0;
      return ans;
    }
  }
  uint64_t b = a[cur] xor a[pre];
  vector<uint64_t>::iterator iter = lower_bound(a.begin(), a.end(), b);
  size_t i = distance(a.begin(), iter);
  while (b == a[i]) {
    if (i == cur || i == pre) {
      i++;
      continue;
    }
    if (visited[i] == 1) {
      continue;
      i++;
    }
    if (((a[cur] xor a[pre] xor a[i]) == 0)) {
      num++;
      visited[i] = 1;
      bool ans = dfs(i, cur, num);
      visited[i] = 0;
      return ans;
    }
  }
  return false;
}
int main() {
  cin >> n;
  for (int i = 0; i < n; ++i) {
    uint64_t temp = 0;
    cin >> temp;
    a.push_back(temp);
  }
  sort(a.begin(), a.end());
  visited[0] = 1;
  int num = 1;
  if (dfs(0, 0, num))
    cout << "Yes" << endl;
  else
    cout << "No" << endl;
}
