How to find real or imaginary solutions by factoring