Show $5n^3+7n^5 \equiv 0$ mod 12 for all integers $n$. I've been stuck on this question for quite a while now. I could obvious show this by setting $n$ to all numbers from 0-11, however this is not very efficient. 
Note $5n^3+7n^5 = n^3(5+7n^2)$. We could use the Chinese remainder theorem, we show $n^3(5+7n^2) \equiv 0 $ mod 3 and mod 4, but this doesn't seem to be any easier. What would be the best way to solve this problem?
 A: $5 \equiv -7 \pmod{12}\,$, so $\,5n^3+7n^5\equiv 7n^3(n^2-1)\equiv 7n^3(n-1)(n+1) \pmod{12}\,$.
All that's left to note is that:


*

*the product of $\,3\,$ consecutive integers $\,(n-1)\,n\,(n+1)\,$ is always a multiple of $\,3\,$, since one of them must be a multiple of $\,3\,$ itself;

*$\,n^2(n-1)(n+1)\,$ is a multiple of $\,4\,$, since either $\,n\,$ is even (in which case $\,n^2\,$ is a multiple of $\,4\,$), or $\,n\,$ is odd (in which case $\,n-1\,$ and $\,n+1\,$ are even, so their product is a multiple of $\,4\,$).
A: If you are familiar with Fermat's/Euler's theorem, then
\begin{align*}
5n^3+7n^5 & \equiv 2n^3+n^5 \pmod{3}\\
& \equiv 2n+n \pmod{3} && \text{using Fermat's theorem}\\
& \equiv 0 \pmod{3}
\end{align*}
Likewise use Euler with mod $4$.
A: Because $$7n^5+5n^3=7(n^5-5n^3+4n)+40(n^3-n)+12n=$$
$$=7\underbrace{(n-2)(n-1)n(n+1)(n+2)}_{3q \space and \space 4q'=12q''}+\underbrace{40(n-1)n(n+1)+12n}_{3q *40=12q'}.$$
A: Oh, geez.....  $7+5 = 12$ so $5n^3 + 7n^5 \equiv 5n^3 - 5n^5 \equiv -7n^3 + 7n^5$.
Suffices to show $12|n^5 - n^3 = n^3(n^2 - 1)= n^3(n+1)(n-1)$.
.....
$n-1, n, n+1$ are three consecutive integers so $3$ divides one of them.
$n-1,n,n+1$ are two consecutive integers so either $2|n$ in which case $8|n^3$, or $2|n-1$ and $2|n+1$ in which case $4|(n-1)(n+1)$.  In either case $4|n^3(n+1)(n-1)$.
So $12|n^3(n+1)(n-1)$  so
$n^3(n+1)(n-1) \equiv 0 \mod 12$
$n^5 - n^3 \equiv 0 \mod 12$
$7n^5 - 7n^3 \equiv 0 \mod 12$
$7n^5 + 5n^3 \equiv 0 \mod 12$.
A: The only quadratic residue mod $3$ is $1$.
The only quadratic residue mod $4$ is also $1$.
Therefore:
\begin{align*}
n^3 &\equiv n^5 \pmod{3} &\qquad n^3 &\equiv n^5 \pmod{4}
\end{align*}
and so
$$ n^3 \equiv n^5 \pmod{12} $$
Applying this to the original equation:
$$ 5n^3 + 7n^5 \equiv 12n^3 \equiv 0 \pmod{12} $$
