#include <bits/stdc++.h>
using namespace std;
int x = 0;
int idx = 0;
int r1 = 0;
int r2 = 0;
bool isOk(vector<int> &V) {
  for (int i = 0; i < 3; i++) {
    for (int j = 1; j <= 3; j++) {
      if (V[i] == j) {
        x = j;
        idx = i;
        r1 = V[(idx + 1) % 3];
        r2 = V[(idx + 2) % 3];
        return true;
      }
    }
  }
  return false;
}
int main() {
  int N;
  cin >> N;
  vector<int> V(N);
  for (int &v : V) cin >> v;
  sort(V.begin(), V.end());
  if (V.size() != 3 || !isOk(V)) {
    cout << "No" << endl;
    return 0;
  }
  if (x == 1) {
    if ((r1 % 4 == 2 && r2 % 4 == 3) || (r1 % 4 == 3 && r2 % 4 == 2)) {
      cout << "Yes" << endl;
      return 0;
    }
  } else if (x == 2) {
    if ((r1 % 4 == 1 && r2 % 4 == 3) || (r1 % 4 == 3 && r2 % 4 == 1)) {
      cout << "Yes" << endl;
      return 0;
    }
  } else if (x == 3) {
    if ((r1 % 4 == 1 && r2 % 4 == 2) || (r1 % 4 == 2 && r2 % 4 == 1)) {
      cout << "Yes" << endl;
      return 0;
    }
  } else {
    cout << "No" << endl;
  }
  cout << "No" << endl;
  return 0;
}
