Given that x is a positive integer, prove that $f(x) = x^2 + x + 1$ will never be divisible by $5$.
I've tried a contrapostive proof so far: Assume $f(x)$ is divisible by $5$. Then, $x^2 + x + 1 = 5p$ for some integer $p$.
$x(x+1) + 1 = 5p$
Since $x(x+1)$ has to be even because an even number times an odd number if even, $x(x+1)$ is odd. Thus, p is odd (the product of 5 and an odd number is an odd number). Thus:
$x(x+1) + 1 = 5(2n+1)$ for some integer $n$.
$x^2 + x - (10n+4) = 0$.
I need to show that x is NOT an integer, but I'm not sure how to proceed from here. Help?
Check $$0^2+0+1\not\equiv0,$$
$$1^2+1+1\not\equiv0,$$
$$2^2+2+1\not\equiv0,$$
$$3^2+3+1\not\equiv0$$ and
$$4^2+4+1\not\equiv0.$$