Divide $ (x^2 + 5x + 6) $ by $ (x + 2) $.
Step 1: Set up the long division. Arrange both the dividend and the divisor in descending powers of the variable.
$ \qquad \qquad \quad x + 2 \overline{) x^2 + 5x + 6} $
Step 2: Divide the first term of the dividend ($ x^2 $) by the first term of the divisor ($ x $). This gives the first term of the quotient ($ \frac{x^2}{x} = x $). Write this term above the dividend.
$ \qquad \qquad \quad \quad x $
$ \qquad \qquad \quad x + 2 \overline{) x^2 + 5x + 6} $
Step 3: Multiply the first term of the quotient ($ x $) by the entire divisor ($ x + 2 $). Write the result below the dividend and subtract it.
$ \qquad \qquad \quad \quad x $
$ \qquad \qquad \quad x + 2 \overline{) x^2 + 5x + 6} $
$ \qquad \qquad \quad \quad -(x^2 + 2x) $
$ \qquad \qquad \quad \quad \overline{\qquad \quad 3x + 6} $ (Subtracting $ x^2 + 2x $ from $ x^2 + 5x $)
Step 4: Bring down the next term of the dividend ($ +6 $).
$ \qquad \qquad \quad \quad x $
$ \qquad \qquad \quad x + 2 \overline{) x^2 + 5x + 6} $
$ \qquad \qquad \quad \quad -(x^2 + 2x) $
$ \qquad \qquad \quad \quad \overline{\qquad \quad 3x + 6} $
Step 5: Repeat the process. Divide the first term of the new dividend ($ 3x $) by the first term of the divisor ($ x $). This gives the next term of the quotient ($ \frac{3x}{x} = 3 $). Write this term above the dividend.
$ \qquad \qquad \quad \quad x + 3 $
$ \qquad \qquad \quad x + 2 \overline{) x^2 + 5x + 6} $
$ \qquad \qquad \quad \quad -(x^2 + 2x) $
$ \qquad \qquad \quad \quad \overline{\qquad \quad 3x + 6} $
Step 6: Multiply the new term of the quotient ($ 3 $) by the entire divisor ($ x + 2 $). Write the result below the current dividend ($ 3x + 6 $) and subtract it.
$ \qquad \qquad \quad \quad x + 3 $
$ \qquad \qquad \quad x + 2 \overline{) x^2 + 5x + 6} $
$ \qquad \qquad \quad \quad -(x^2 + 2x) $
$ \qquad \qquad \quad \quad \overline{\qquad \quad 3x + 6} $
$ \qquad \qquad \quad \quad -(3x + 6) $
$ \qquad \qquad \quad \quad \overline{\qquad \quad \quad \quad 0} $ (Subtracting $ 3x + 6 $ from $ 3x + 6 $)
Step 7: The process stops when the remainder is 0 or its degree is less than the degree of the divisor.
The quotient is $ x + 3 $ and the remainder is $ 0 $.