I have the following problem:
If p is prime, prove that the only solutions of (x^2)+x=0 in Zp are 0 and p-1.
Ok I did this:
I re-wrote (x^2)+x=0 in Zp to (x^2)+x=0 (mod p). If this is true, then p divides (x^2)+x. I factored (x^2)+x to x(x+1) and since p is prime, I know that either p divides x or p divides (x+1). I then concluded that x=0 (mod p) or x=-1 (mod p). How do I put these back into terms like 0 and p-1 in the question?
Thanks for any help.

