What is the number of integral values of $k$ for which the equation $|x^2 - 5|x| + 6|=k$ has four solutions is? I have done the sum by first plotting the graph of the function in the Left Hand Side of the equation and then plotted the line $y=k$. For the equation to have $4$ solutions, both these two curves must intersect at $4$ different points, and from the two graphs, I could see that for the above to occur, the value of $k$ must lie between $\cfrac{1}{4}$ and $6$, that is k belongs to $( 0.25,6)$. Thus , the integral values of $k$ would be  $1,2,3,4,5$; and so the number of integral values of $k = 5$. This was the answer given in the book. But as I was looking at the graph, I realized that $k=0$ also gives $4$ solutions namely $x=-2,-3,2,3$. So, should the number of integral values of $k$ be $6$ $(0,1,2,3,4,5)$? 

Let $f(x)=|x^2-5|x|+6|$. Note that $f(x)=f(-x)$.
$f(0)=6$. So, when $k=6$, the number of solutions of $f(x)=k$ is odd.
When $k\ne6$, the number of solution is double the number of solution of $f(x)=k$ for $x>0$. It suffices to find $k$ such that $f(x)=k$ has two solutions in $(0,\infty)$.
For $x>0$, $f(x)=|x^2-5x+6|$.
Obviously, $f(x)=k$ has solutions only when $k\ge0$.
When $k=0$, the solutions are $2$ and $3$.
$x^2-5x+6=k$ has two distinct positive roots if $0\le k<6$ and one positive root if $k>6$.
Note that $x^2-5x+6=-k$ has discriminant $5^2-4(6+k)=1-4k$. So $x^2-5x+6=-k$ has one positive root when $k=0.25$ and two distinct positive roots when $0\le k<0.25$.
So, $f(x)=k$ has two distinct positive roots if and only if $k=0$ or $0.25<k<6$.

Graphical Method:

I think you are correct. $k=0,1,2,3,4$ or $5$.
