Given a number $N$, I want to determine $\vert\{x\in\mathbb{N}\ \vert\ 1\leq x\leq N\wedge\ \text{candidate}(x)\}\vert$
where
$\text{candidate}(x) = \vert\{y\in\mathbb{N}\ \vert\ 1\leq y < x \wedge x \mod y = 0\}\vert\ \mod 2 = 0$
Really stuck with this and would appreciate some help.
The candidates are precisely the perfect squares (because all divisors $d\ne\sqrt x$ come in pairs $d,\frac xd$, where special care is needed for $1$ and $x$). Hence the desired number is $\lfloor\sqrt N\rfloor$.