You have the following polynomial:
2 + 12p - 9p - x - 10x +10
In order to simplify the previous expression you proceed as follow:
2 + 12p - 9p - x - 10x +10
first, simplify similar term, terms with p, terms with x and independent terms, as follow:
(12p - 9p) + (- x - 10x) + (10 + 2)
In the previous line similar terms were grouped. You subtract 12 and 9 for variable p, sum 1 and 10 for variable x (by taking into account that is a sum of negativ numbers) and sum 10 and 2 for number without variables. Thus, you obtain:
3p - 11x + 12
Hence the simplified expression is 3p - 11x + 12