#include <bits/stdc++.h>
using namespace std;
int main() {
  int n, m[100], a;
  string s;
  cin >> n;
  for (int i = 0; i < n; i++) cin >> m[i];
  for (int i = 0; i < n; i++) a = m[i] * m[i + 1];
  if (a % 4 == 0)
    s += "YES";
  else if (a % 4 == 0)
    s += "NO";
  cout << s;
}
