I know that $x^2+x-1$ does not factor over the integers but $x^2+x-2$ does (i.e.: (x+2)(x-1)). If I have expressions of the form $x^2+x - n$ $\forall n \leq 2018$, how many of the expressions factor for $n \leq 2018$? I'm trying to notice a pattern because for the first 21 of these expressions I have that:
n = 2, 6, 12, 20 factor but the rest don't. How can I solve this?