Prove: If $p$ is prime and $ (a,p)=1 $, then $\ 1 + a + a^2 + ... + a^{p-2}=0$(mod $p$) Prove: If $p$ is prime and $ (a,p)=1 $, then $\ 1 + a + a^2 + ... + a^{p-2}≡0 \pmod p$
As an example, for $a=2$ and $p=5$, then:
$$1+2+2^2+2^3=1+2+4+8=15≡0 \pmod 5$$
This can also be written as:
$$1 \pmod 5 + 2 \pmod 5 + 4 \pmod 5 + 3 \pmod 5 ≡ 10 \pmod 5 ≡ 0 \pmod 5$$
Which is a complete residue system (mod 5). This is where I'm stuck. At a glance it looks like fermat's little theorem, but it seems like I have to prove this creates a CRS for any $a$ and any $p$. How can I proceed? Thanks!

Hint: $\mathbb{Z}_p = \mathbb{Z}/p\mathbb{Z}$ is a field, and, in this field,
$$
(a-1)(1+a+a^2 + \ldots + a^{p-2}) = (a^{p-1}-1)
$$
