Challenge Stand in Line has an issue.
User Agent is: Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/53.0.2785.143 Safari/537.36.
Please describe how to reproduce this issue, and include links to screenshots if possible.
My code:
function nextInLine(arr, item) {
// Your code here
testArr.push(item);
return testArr.shift(); // Change this line
}
// Test Setup
var testArr = [1,2,3,4,5];
// Display Code
console.log("Before: " + JSON.stringify(testArr));
console.log(nextInLine(testArr, 5)); // Modify this line to test
console.log("After: " + JSON.stringify(testArr));
Challenge works fine and here is an example of that. Problem is in your code, so check it again and tell me how it goes ;)

By the way, you need to change the code and not leave it like you got it. It won't let you pass...
@ahmedghandour you have a small error in your code. In the future, please post in the HelpJavascript Gitter channel first. If the consensus there is that it is a bug, then you should post here.
@ahmedghandour thanks for the issue but if you get stuck or have questions with a challenge in the future, please first ask questions to the Help Room. Hint: please review your knowledge of function scope. You can only use variables that are scoped by your function. Happy coding!
Thanks guys, I'll try again and again until it is Ok, and I'll post in the help it was my mistake
Thanks a lot erictleung, you've been of great help. Thanks again.
I passed the challenge.
Most helpful comment
@ahmedghandour thanks for the issue but if you get stuck or have questions with a challenge in the future, please first ask questions to the Help Room. Hint: please review your knowledge of function scope. You can only use variables that are scoped by your function. Happy coding!