When factorizing an expression containing 4 terms, we group them into 2 terms each before factorizing.
Example 1: Factorize ab+ac+mb+mc
Solution
Ab+ac+mb+mc = (ab+ac) + (mb+mc)
(Ab+ac)+(mb+mc)=a (b+c) + m (b+c)
A (b+c) = m (b+c) = (b+c)(a+m)
Ab+ac+mb+mc = (b+c) (a+m)
Example 2: Factorize a²+da+pa+pd
Solution
A²+da+pa+pd = (a²+da) + (pa+pd)
(a²+da) + (pa+pd) = a (a+d) +p(a+d)
a(a+d) +p(a+d) = (a+d)(a+p)