Let $f(x)=\cos^{-1}(\cos x)$.
a) What does $f(x)$ mean and what should it be?
A: $f(x)=\cos^{-1}(\cos x)=x$.
b) Test your answer in a) for $x=1,\;2,\;3,\;4$.
A: $f(1)=1,\;f(2)=2\;,f(3)=3,\;f(4)\neq 4$
c) Explain the result in b).
Translation: If $\cos\;x=k$ and $\cos^{-1} k=x$, $\cos x$ must be limited to an interval where every allowed $k$ gives one $x$. We have chosen $0\leq x\leq\pi$. For $x>\pi$ we get the $x$ in this interval for which $\cos\;x=\cos4$.
I do not understand their explanation. Could someone write/explain it in another way?

Since the cosine function is periodic, it does not have an inverse unless we restrict its domain to an interval in which it is injective, meaning that there is one value of $x$ in the domain for each value of $y$ in the range. By convention, we take the restricted domain to be $[0, \pi]$. Thus, we need the inverse of the function $g: [0, \pi] \to [-1, 1]$ defined by $g(x) = \cos x$.
The inverse of $g$ is called the arccosine function, denoted $h(x) = \arccos x$ or $h(x) = \cos^{-1}x$. It maps the interval $[-1, 1] \to [0, \pi]$ and is defined by $$h(x) = \arccos x = y \iff \cos y = x~\text{and}~y \in [0, \pi]$$
Therefore, the restriction of the function $f: \mathbb{R} \to [0, \pi]$ defined by $f(x) = \arccos(\cos x)$ to the interval $[0, \pi]$ is the identity function on that interval. Thus, \begin{align*} f(1) & = 1\\ f(2) & = 2\\ f(3) & = 3 \end{align*} However, outside the interval $f(x) = t$ if $t$ is the value in $[0, \pi]$ such that $\cos x = \cos t$ since $$f(x) = \arccos(\cos x) = \arccos(\cos t) = t$$
where $t \in [0, \pi]$.
Since $4 > \pi$, we must find the value of $t \in [0, \pi]$ such that $f(4) = \cos t$. Since $\cos(\pi + x) = -\cos x$, $$\cos(4) = \cos(\pi + 4 - \pi) = -\cos(4 - \pi)$$
Since $\cos(\pi - x) = -\cos x$, $$\cos(4) = -\cos(4 - \pi) = \cos(\pi - (4 - \pi)) = \cos(2\pi - 4)$$ Moreover, $2\pi - 4 \in [0, \pi]$. Hence, $$f(4) = 2\pi - 4$$