Computing limits with algebra

When substitution gives $\frac{0}{0}$, simplify (factor, cancel, or multiply by a conjugate) to an expression that agrees away from the point, then substitute.

From Calculus 1.