#include <bits/stdc++.h>
using namespace std;
int main() {
  int N;
  int twos, fours, nons;
  twos = fours = nons = 0;
  const int MAXN = 1e5 + 5;
  vector<int> a(MAXN, 0);
  cin >> N;
  for (int i = 1; i <= N; ++i) {
    cin >> a[i];
    if (a[i] % 4 == 0)
      ++fours;
    else if (a[i] % 2 == 0)
      ++twos;
    else
      ++nons;
  }
  bool failure = false;
  for (int i = 1; i <= N - 1; ++i) {
    if ((a[i] % 2) != 0) {
      if (fours)
        --fours;
      else
        failure = true;
    } else {
      if ((a[i] % 4) == 0) {
        if (nons)
          --nons;
        else if (twos)
          --twos;
        else
          --fours;
      } else {
        if (twos)
          --twos;
        else if (fours)
          --fours;
        else
          failure = true;
      }
    }
  }
  if (failure)
    cout << "No" << endl;
  else
    cout << "Yes" << endl;
  return 0;
}
