The title is the problem.
The condition "has two distinct roots" is ambiguous, but I assume it to be ``having exactly two distinct roots".
The title is the problem.
The condition "has two distinct roots" is ambiguous, but I assume it to be ``having exactly two distinct roots".
Here are the number of real roots as $k$ varies: $$ \begin{cases} 0,&k<-1\\ 1,&k=-1\\ 2,& -1<k<2\\ 3,& k=2\\ 4,& 2<k<3\\ 3,& k=3\\ 2,& k>3 \end{cases} $$
To see why, plot $|x^2-3x|-x+2$:
Then the number of real roots for a given $k$ corresponds to the number of points in the horizontal slice at height $k$ of this graph.
For a formal proof, you can split up into cases based on if $x\in [0,3]$ or not; then the equation splits up into two quadratic equations.