#include <bits/stdc++.h>
using namespace std;
int main() {
  int n, i, sum = 0;
  cin >> n;
  int arr[n];
  for (i = 0; i < n; i++) cin >> arr[i];
  for (i = 0; i < n; i++) sum = sum ^ i;
  if (sum == n)
    cout << "Yes" << endl;
  else
    cout << "No" << endl;
}
