Answer :

f(x) = x² - 2x + 8
f(x) = x² - 4x + 2x + 8
f(x) = x(x) - x(4) + 2(x) - 2(4)
f(x) = x(x - 4) + 2(x - 4)
f(x) = (x + 2)(x - 4)