The relation to be represented in graph is as follows
$$ y = k \text{ for } k-1 < |x| < k \text{ where } k\in \mathbb Z $$
Normally we plot the area where the relation holds good is where the graphs overlap , But here they don't seem to overlap. So I don't know how to plot the graph ?
I tried it in wolfram alpha to see how the graphs |x| > k-1 and |x| < k look separately and from which the overlapping area is where the entire relation holds good (I assumed k=2 for plotting)
for |x|<2
for |x| >1
One graphs area is outside the |x| boundary and other area is within it . How can the area overlap , how can I plot the relation in graph for the combined relation which I gave in line 2 of this question .
But the answer for this relation was given in a book as following

May I know how they arrived at this solution . Please correct me where I am going wrong in my understanding .
Thanks