#include <bits/stdc++.h>
using namespace std;
using ll = long long;
using vi = vector<int>;
using mti = vector<vector<int>>;
using vl = vector<ll>;
using mtl = vector<vector<ll>>;
using pi = pair<int, int>;
using pl = pair<ll, ll>;
signed main() {
  int n;
  cin >> n;
  vl vec(n);
  for (int i = 0; i < (int)(n); i++) {
    ll a;
    cin >> a;
    vec[i] = a;
  }
  string ans = "No";
  do {
    bool ok = true;
    for (int i = 0; i < (int)(n - 1); i++) {
      if (vec[i] % 4 == 0 || vec[i + 1] % 4 == 0)
        continue;
      else if (vec[i] % 2 == 0 && vec[i + 1] % 2 == 0)
        continue;
      else
        ok = false;
    }
    if (ok) {
      ans = "Yes";
      break;
    }
  } while (next_permutation(vec.begin(), vec.end()));
  cout << ans;
  return 0;
}
