Ok so, I had a math test. And I need help understanding some of the questions.

Solve for x.
11) x(x-5)(x+12)=0
x=0
x=?
x=?
I know that x can equal 0 and apparently the other answers where 5 and -12 and I've been trying to figure it out for hours but I still don't know how do you find and get these answers? Could someone explain???

Another example from my test is:

12) (x-2)(x-3)(2x+1)=0
x=?(Answer is 2)
x=?
x=?(Answer is -[tex]\frac{1}{2}[/tex]
How do I figure this outtt???

I swear if annoying trolls come in just for the points I will report.