Prove that $x^p\equiv 1$ (mod $p$) has only one solution. I know that said solution is $x\equiv 1$ (mod $p$). However, I'm having difficulty proving this result. 
So far, I've tried $x^p\equiv 1$ (mod $p$) $ \Rightarrow $ $p\mid (x^p-1) \Rightarrow p\mid(x-1)(x^{p-1} + x^{p-2} + \cdots + x + 1)$. 
From here, it's clear that the objective is to somehow show that $p\mid(x^{p-1} + x^{p-2} + \cdots + x + 1)$ also yields $x\equiv 1$ (mod $p$), but I've been unsuccessful in showing this after $(x^{p-1} + x^{p-2} + \cdots + x)\equiv-1$ (mod $p$).

$(x-1)^p \equiv (x^p - 1) \mod p$  by binomial theorem. So, if $p$ divides $(x^p - 1)$, it certainly divides $(x-1)^p$. Therefore, by fermat's last theorem, $p$ divides $x-1$. Hence, you get the desired result.
