These are applications of the remainder and factor theorems. If a polynomial $\displaystyle \begin{align*} P(x) \end{align*}$ is divided by $\displaystyle \begin{align*} (x - \alpha ) \end{align*}$, then the remainder is equal to $\displaystyle \begin{align*} P \left( \alpha \right) \end{align*}$.