Example 1. Let $k$ be a real number, discuss the real roots of the equation
$$
\left|x^{2}-1\right|-x-k=0
$$
Solve by discussing the relationship between the intersection points of images and the solutions of equations. Let $y=f_{1}(x)=\left|x^{2}-1\right|$ and $y=f_{2}(x)=x+k$. Sketch the graphs of these two functions, and note that $y=x+k$ is a set of lines parallel to $y=x$. Thus, we can obtain a partition of the set of real numbers:
$$
\begin{array}{ll}
(-\infty,-1), \\
\{-1\}, & (-1,
\end{array}
$$
1), $\{1\},\left(1, \frac{5}{4}\right),\left\{\frac{5}{4}\right\},\left(\frac{5}{4}, \infty\right)$.

The number of solutions to the original problem in each part is 0, 1,
$$
2,3,4,3,2
$$