(x−3)(x−4)
How?
(You don't need to write all of this, but it is the reason we get the answer we get.)
(ax+b)(cx+d)=(ab)x2+(ad)x+(bc)x+(bd)=(ab)x2+(ad+bc)x+(bd)
This expression has : 1x2+(−7)x+(12), so we want ac=1.
With whole numbers that means we have a=1 and b=1. That makes this easier (or less difficult).
(x+b)(x+d)=x2+(d+b)x+bd
Now we need bd=12. With whole numbers let's look at the possibilities:
1⋅12=12
2⋅6=12
3⋅4=12
4⋅ no, stop. We already see 4 on the right, so we can stop
Thinking a bit more, we want bd=+12, so we need either both b and d are positive or both are negative.
Now look at the middle term −7x.
The −7 needs to be d+b. We already knew that either both are positive or both are negative, but if both are positive, they would add up to a positive, so we need both to be negative and they have to add up to −7. Looking at the list of possibiities we see 3⋅4. If we make both negative, they multiply to give us +12 and the add up to −7 That's what we wanted, so let's make sure it works:
(x−3)(x−4)=x2−4x−3x+12=x2−7x+12 and that's what we wanted.
Notes:
Explaining it takes a lot longer than doing it.
The more practice you get, the faster and easier it gets to factor.
For more complicated problems, there are other methods you can learn.