#include <bits/stdc++.h>
using namespace std;
int main() {
  int n, a, b, c;
  cin >> n;
  if (n != 3) {
    cout << "No";
    return 0;
  }
  cin >> a >> b >> c;
  if (a ^ b == c)
    cout << "Yes";
  else
    cout << "No";
}
