#include <bits/stdc++.h>
using namespace std;
int main() {
  int n, c = 0, j, x = 0;
  int a[200] = {0};
  scanf("%d", &n);
  for (int i = 1; i <= n; i++) {
    scanf("%d", &j);
    a[j]++;
  }
  for (int i = 1; i < 110; i++) {
    {
      if (i % 2 != 0) {
        x = x + a[i];
      } else
        c = c + a[i];
    }
  }
  if (x % 2 == 0)
    cout << c << endl;
  else
    cout << x;
  return 0;
}
