How do you factorise x^2 − 7 x + 12?
It is done by splitting the middle terms such the coefficients ad up to -12 and their product is +12.
In the present case -7x can be split as -3x and -4x. The multiplication of coefficients also gives +12. Accordingly,
Now pair up te terms #(x^2-3x) +(-4x +12)
Extract common factors x(x-3)-4(x-3)