To make the division we first write it in standard division form:
Now, we need to divide the first term of the dividend by the first term of the divisor, that is:
We write this above the first term and multiply it by the divisor; we write the result below the dividend with the signs change:
Now we add the dividend with what we found in the previous step and write the result below:
Now we take the same steps as before using the first term of the residual we found and the divisor until we have a residual with a degree lower than the degree of the divisor; this is shown below:
Therefore, the we have that the result is: