-
Notifications
You must be signed in to change notification settings - Fork 1.4k
Stand in Line任务有Bug
Tyrion Yu edited this page May 30, 2018
·
1 revision
function queue(arr, item) { // 请把你的代码写在这里 testArr.push(item); return testArr.shift(); // 请修改这一行 }
// 初始化测试数据 var testArr = [5,6,7,8,9];
// 控制台输出 console.log("Before: " + JSON.stringify(testArr)); console.log(queue(testArr, 1)); // 你可以修改这一行来测试你的代码 console.log("After: " + JSON.stringify(testArr));