<s>[INST] Always divisible by $5$ Find the number of ordered 8-tuples $(a_7,a_6,\ldots,a_0) $ of nonnegative integers such that $0 \le a_i \le 4$ for all $i$, and
$$a_7n^7+a_6n^6+a_5n^5+a_4n^4+a_3n^3+a_2n^2+a_1n+a_0 \equiv 0 \pmod{5}$$
for all integers $n$. I tried placing $n=0,+1,-1$ but  don't think it solves the problem. 
 [/INST] Hint #1

If the polynomial $$f = a_{7} x^{7} + a_{6} x^{6} + \dots + a_{1} x +  a_{0} \in \mathbb{Z}/5 \mathbb{Z}[x]$$ vanishes on $\mathbb{Z}/5 \mathbb{Z}$, it must be a multiple of $x^{5} - x \in \mathbb{Z}/5 \mathbb{Z}[x]$.

Hint #2

So $f = (x^{5} - x) \cdot g$, where $g$ is an arbitrary polynomial of degree $7 - 5 = 2$. How many $g$ there are?

Hint #3

So we get $$ f = (x^{5} - x) (b_{2} x^{2} + b_{1} x + b_{0}) = b_{2} x^{7} + b_{1} x^{6} + b_{0} x^{5} - b_{2} x^{3} - b_{1} x^{2} - b_{0} x.$$ So we have $5^{3}$ such polynomials, and exactly as in the answer of Geoff Robinson, they are characterized by $a_{0} = a_{4} = 0$, $a_{7} = - a_{3}$, $a_{6} = - a_{2}$, and $a_{5} = - a_{1}$.

</s>