How do you factor this?

Step 1. Split the second term in 2x^2 - x - 21 into two terms
2x^2 + 6x - 7x - 21
Step 2. Factor out the common terms in the first two terms, then in the last two terms.
2x(x + 3) -7(x + 3)
Step 3. Factor out the common term x + 3
(x + 3)(2x - 7)