>Can someone explain how we factorized here to get the 2
It's not factorization, it's simplification:
3/2 - 1 = 1/2
And dividing by 1/2 is the same as multiplying by 2
>and where does the -3 come from in the last part?
It comes from distributing the 2 inside the outer parenthesis. 2\*-1 = -2, then you subtract the 1 which makes it -3.