#include <bits/stdc++.h>
using namespace std;
int gcd(int a, int b) { return b == 0 ? a : gcd(b, a % b); }
const int MAXN = 1e5 + 10;
int arr[MAXN];
int main() {
  int n;
  while (cin >> n) {
    int t;
    for (int i = 0; i < n; ++i) {
      cin >> arr[i];
      if (i == 0)
        t = arr[i];
      else
        t = gcd(t, arr[i]);
    }
    if (t > 1) {
      cout << "YES" << endl << 0 << endl;
      continue;
    }
    int ans = 0;
    for (int i = 0; i < n - 1; ++i) {
      while (1) {
        if (arr[i] % 2 == 0) break;
        ans++;
        int a1 = arr[i] - arr[i + 1], a2 = arr[i] + arr[i + 1];
        arr[i] = a1;
        arr[i + 1] = a2;
      }
    }
    if (arr[n - 1] % 2 == 1) ans += 2;
    cout << "YES" << endl << ans << endl;
  }
  return 0;
}
