I was going through "The Art of Problem Solving - Prealgebra" textbook and I noticed that one of the examples include a proof for (-1)x + x = 0
My solution differs from their proof, but here's what I came up with:
Prove: (-1)x + x = 0
Proof:
(-1)x + (-(-x)
(-1)0 = 0
Does this look correct?
You have to be careful, because the specifics of the proof will depend on what's already been given to you - I'm going to guess that the book has already covered some basic axioms of arithmetic and has proven that $0 \times x = 0$. Then you can do the following:
$$\begin{eqnarray} (-1)x + x & = & (-1)x + 1x & \text{multiplicative identity}\\ & = & ((-1) + 1) x & \text{by the distributive property} \\ & = & (0)x & \text{additive inverse} \\ & = & 0 & \text{already proven?} \\ & = & -x + x & \text{additive inverse} \end{eqnarray}$$
and you can then conclude that $(-1)x = -x$, i.e. multiplying $x$ by the additive inverse of 1 gives the additive inverse of $x$.
The important thing in each step is to check that you're only ever replacing like with like - i.e. that you have an axiom, or previously proven result, showing that two things are equal, because these kinds of proof are about rigorously deriving results we usually take for granted. There are a lot of structures in mathematics that follow some but not all of the same rules, so there's no guarantee that these proofs will work (for example, we might have only addition or multiplication but not both, or we might have both but they don't have the distributive property).