#include <bits/stdc++.h>
using namespace std;
int a, b, c, d, i, e, f, g, n, m, k, l, x, A[102];
int main() {
  cin >> n;
  for (i = 1; i <= n; i++) {
    cin >> A[i];
    x += A[i];
  }
  for (i = 1; i <= n; i++)
    if ((x - A[i]) % 2 == 0) a++;
  cout << a;
}
