$$ \begin{aligned} 10 &= 6+2p-p&& \text{simplify right side} \\[1 em]10 &= p+6&& \text{ swap the left and right side of the equation } \\[1 em]p+6 &= 10&& \text{ move 6 to the right } \\[1 em]p &= 10-6&& \\[1 em]p &= 4&& \\[1 em]p &= 4&& \\[1 em] \end{aligned} $$