Answer
$k=5$
Work Step by Step
The factor theorem states that when $f(a)=0$, then we have $(x-a)$ as a factor of $f(x)$ and when $(x-a)$ is a factor of $f(x)$, then $f(a)=0$.
We simplify the given equation as follows:
$f(2)=2^3-k(2)^2+(2)k+2=0 \\ 8-4k+2k+2=0\\ 10-2k=0\\2k =10 \\ k=5$