#include <bits/stdc++.h>
using namespace std;
template <class T>
T sqr(T x) {
  return x * x;
}
long double pi = 3.1415926535897932384626433832795;
long long mod = 1e9 + 7;
long long gcd(long long a, long long b) { return b ? gcd(b, a % b) : a; }
long long _gcd(long long a, long long b, long long& x, long long& y) {
  if (a == 0) {
    x = 0;
    y = 1;
    return b;
  }
  long long _x1, _y1;
  long long d = _gcd(b % a, a, _x1, _y1);
  x = _y1 - (b / a) * _x1;
  y = _x1;
  return d;
}
long double binpow(long double a, long long n) {
  long double res = 1;
  while (n) {
    if (n & 1) res *= a;
    a *= a;
    n >>= 1;
  }
  return res;
}
const int N = 2e5 + 10;
long double prob(long long k, long long days) {
  vector<long long> num, denom;
  for (int i = 0; i < k; i++) {
    num.push_back(days - i);
  }
  for (int i = 1; i <= k; i++) denom.push_back(k);
  for (int i = k; i > 1; i--) denom.push_back(i);
  long double res = 1;
  int ptr = 0;
  for (int i = 0; i < k; i++) {
    res *= num[i];
    while (res > 1 && ptr < denom.size()) res /= denom[ptr++];
  }
  for (int i = ptr; i < denom.size(); i++) res /= denom[i];
  return res;
}
int cnt[211];
int main() {
  memset(cnt, 255, sizeof(cnt));
  cnt[0] = 0;
  for (int i = 1; i <= 60; i++) {
    for (int j = 60; j >= 0; j--) {
      if (cnt[j] != -1) cnt[i + j] = max(cnt[i + j], cnt[j] + 1);
    }
  }
  int n;
  cin >> n;
  int res = 0;
  for (int i = 0; i < n; i++) {
    int t;
    cin >> t;
    res ^= cnt[t];
  }
  if (res)
    cout << "NO";
  else
    cout << "YES";
  return 0;
}
