function nextInLine(arr, item) {
// Your code here
arr.push(item);
removed = arr.shift();
return removed; // Change this line
}
// Test Setup
var testArr = [];
// Display Code
console.log("Before: " + JSON.stringify(testArr));
console.log(nextInLine(testArr, 1)); // Modify this line to test
console.log("After: " + JSON.stringify(testArr));
nextInLine(testArr, 1)
nextInLine(arr, item) {