First we return the entire array in line one
In line 2 we use the pop method to show what we poped out.
On line 3 we show the remaining 2 items of the array.