#include<iostream>
#include<cstdio>
#include<algorithm>
#include<string>
#include<vector>
#include<queue>
#include<set>
#include<stack>
#include<functional>
#include<list>
#include<map>
#include<unordered_map>
#define int long long
using namespace std;

signed main() {
	int a;
	cin >> a;
	int s = 0;
	for (int b = 0; b < a; b++) {
		int c; scanf("%lld", &c);
		bool k = true;
		for (int d = 1; d*d <= c; d++) {
			if ((c - d) % (2 * d + 1) == 0) { k = false; break; }
		}
		if (k)s++;
	}
	cout << s << endl;
}