#include <bits/stdc++.h>
using namespace std;
using ll = long long;
using P = pair<ll, ll>;
using Graph = vector<vector<ll>>;
const int dx[4] = {1, 0, -1, 0};
const int dy[4] = {0, 1, 0, -1};
const int ddx[8] = {0, 1, 1, 1, 0, -1, -1, -1};
const int ddy[8] = {1, 1, 0, -1, -1, -1, 0, 1};
const ll MOD = 1000000007;
const ll INF = 1000000000000000000L;
map<ll, ll> prime_factorize(ll N) {
  map<ll, ll> res;
  for (ll i = 2; i * i <= N; ++i) {
    while (N % i == 0) {
      res[i]++;
      N /= i;
    }
  }
  if (N != 1) res[N] = 1;
  return res;
}
void Main() {
  ll N;
  cin >> N;
  map<ll, ll> cnt;
  for (ll i = 0; i < (ll)(3); i++) {
    cnt[i] = 0;
  }
  for (ll i = 0; i < (ll)(N); i++) {
    ll tmp;
    cin >> tmp;
    map<ll, ll> res = prime_factorize(tmp);
    if ((res.size() > 0) && (res.find(2) != res.end())) {
      ll ind = (res[2] > 2) ? 2 : res[2];
      cnt[ind] += 1;
    } else {
      cnt[0] += 1;
    }
  }
  if (cnt[1] == 0) {
    string ans = (cnt[2] + 1 >= cnt[0]) ? "Yes" : "No";
  } else {
    string ans = (cnt[2] >= cnt[0]) ? "Yes" : "No";
  }
}
int main() {
  cin.tie(nullptr);
  ios::sync_with_stdio(false);
  cout << fixed << setprecision(15);
  Main();
  return 0;
}
