Finding complex and real roots of polynomials