#include <bits/stdc++.h>
using namespace std;
int main(void) {
  int n;
  cin >> n;
  vector<int> arr(n);
  for (int i = 0; i != n; i++) cin >> arr[i];
  if (n != 3) {
    cout << "No" << endl;
    return 0;
  }
  if ((arr[0] ^ arr[1]) == arr[2] || (arr[1] ^ arr[2]) == arr[0] ||
      (arr[2] ^ arr[0]) == arr[1])
    cout << "Yes" << endl;
  return 0;
}
