function nextInLine(arr, item) {
// Your code here
return arr.shift(), arr.push(item);// Change this line
}
// Test Setup
var testArr = [1,2,3,4,5];
// Display Code
console.log("Before: " + JSON.stringify(testArr));
console.log(nextInLine(testArr, 6)); // Modify this line to test
console.log("After: " + JSON.stringify(testArr));
This is what I have but I am still missing a return of 2 and not sure how to print or why it isnt printing out