x2+3x+2 x+2 1
x2+5x+6 x+3 1
x2+7x+12 x+4 1
Add -1 times row 1 to row 2 and replace row 2 with the result
Add -1 times row 1 to row 3 and replace row 3 with the result:
x2+3x+2 x+2 1
2x+4 1 0
4x+10 2 0
Expand along column 3: determinant = 1[(2x+4)(2) - (1)(4x+10)] + 0 + 0
= 4x+8-4x-10 = -2