#include <bits/stdc++.h>
using namespace std;
int main() {
  int n, arr[100], i, s = 0, ans = 0;
  cin >> n;
  for (i = 0; i < n; i++) cin >> arr[i], s += arr[i];
  for (i = 0; i < n; i++)
    if ((s - arr[i]) % 2 == 0) ans++;
  cout << ans;
  return 0;
}
