# Stand in line exercise, not sure what I am missing here?

**URL:** <https://forum.freecodecamp.org/t/stand-in-line-exercise-not-sure-what-i-am-missing-here/93296>\
**Category:** General\
**Created:** [March 4, 2017, 3:57am UTC](https://forum.freecodecamp.org/t/stand-in-line-exercise-not-sure-what-i-am-missing-here/93296 "2017-03-04T03:57:59Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![Epic-Luc](https://avatars.discourse-cdn.com/v4/letter/e/b3f665/32.png) [@Epic-Luc](https://forum.freecodecamp.org/u/Epic-Luc)\
**Post date:** [March 4, 2017, 3:58am UTC](https://forum.freecodecamp.org/t/stand-in-line-exercise-not-sure-what-i-am-missing-here/93296/1 "2017-03-04T03:58:00Z")

</div>

```javascript
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

---

<div class="post-metadata">

**Author:** ![Epic-Luc](https://avatars.discourse-cdn.com/v4/letter/e/b3f665/32.png) [@Epic-Luc](https://forum.freecodecamp.org/u/Epic-Luc)\
**Post date:** [March 4, 2017, 5:00am UTC](https://forum.freecodecamp.org/t/stand-in-line-exercise-not-sure-what-i-am-missing-here/93296/2 "2017-03-04T05:00:19Z")

</div>

had to do something completely different and step away but I figured it out xD

---

<div class="post-metadata">

**Author:** ![ArielLeslie](https://sea3.discourse-cdn.com/freecodecamp/user_avatar/forum.freecodecamp.org/arielleslie/32/264841_2.png) [@ArielLeslie](https://forum.freecodecamp.org/u/ArielLeslie)\
**Post date:** [March 4, 2017, 6:17pm UTC](https://forum.freecodecamp.org/t/stand-in-line-exercise-not-sure-what-i-am-missing-here/93296/3 "2017-03-04T18:17:40Z")

</div>

I cleaned up your code.  
You need to use triple backticks to post code to the forum.  
See [this post for details](http://forum.freecodecamp.com/t/forum-code-formatting/25574).

---

<div class="post-metadata">

**Author:** ![ILM](https://sea3.discourse-cdn.com/freecodecamp/user_avatar/forum.freecodecamp.org/ilm/32/363239_2.png) [@ILM](https://forum.freecodecamp.org/u/ILM)\
**Post date:** [January 16, 2021, 6:03pm UTC](https://forum.freecodecamp.org/t/stand-in-line-exercise-not-sure-what-i-am-missing-here/93296/4 "2021-01-16T18:03:38Z")

</div>

Closed on January 16, 2021, 6:03pm UTC


