How do you factor #x^4 - x^3 - 5x^2 - x - 6#?
Using the Rational Zeros Theorem the solution is
If you have a polynomial with integer coefficients you can try to find the solutions applying the Rational Zeros Theorem.
This theorem says that if a root is rational, it has to have the numerator as one of the factors of the constant and the denominator as one of the factors of the coefficient of the leading term.
It is easier to see in your case.
First of all your polynomial has the coefficients integers, they are
The coefficient of the leading term is
The constant term is
The theorem tells us that if a rational root exists it must be one of this
Then we try all of them and see if we obtain zero
We were lucky and we found two roots,
Then we can start our factorization as
The part that is missing is the quadratic polynomial
If we multiply the terms we have
if we compare this with the initial polynomial
Then the final factorization is
If you want to factorize in the complex numbers you can write