①x^2-y^2+a^2-b^2+2ax+2by
=x^2+2ax+a^2-b^2+2by-y^2
=(x+a)^2-(b-y)^2
=(x+a+b-y)(x+a-b+y)
②4-(x^2-4x+2)^2
=(2+x^2-4x+2)(2-x^2+4x-2)
=(x^2-4x+4)(-x^2+4x)
=[(x-2)^2][-x(x-4)]
=-x(x-2)^2(x-4)
③a^2-ab+ac-bc
=a(a-b)+c(a-b)
=(a-b)(a+c)
④m^2-5m-mn+5n
=m(m-5)-n(m-5)
=(m-5)(m-n)
⑤x^2-x-12
=(x-4)(x+3)