7 kyu

Training JS #23: methods of arrayObject---push(), pop(), shift() and unshift()

2,712 of 2,711myjinxin2015
Description
Loading description...
Fundamentals
Tutorials
  • Please sign in or sign up to leave a comment.
  • GriezL07 Avatar

    How does parameter d work? Can anyone explain?

  • ptihiy Avatar

    What's wrong with the completions counter? 2,467 of 2,466.

  • ejini战神 Avatar

    Fixed and sample tests should have cases when n exceeds the bound of the array (i.e, longer than the given array's length)

  • Cloud Walker Avatar

    Nice kata. Strange how so many solutions look almost exactly the same :)

  • laurelis24 Avatar

    Very nice kyu. A little reminder about array methods.

  • farhanaditya Avatar

    JS: Node v14 should be used along with its appropiate assertion tools (Mocha + Chai). Refer to this and this

  • Anti-RakPro Avatar

    i thought there would be more than 3 arrays as a test check , but no. good task

  • jackpockninja Avatar

    Thought this was pretty challenging! Are us beginners meant to know what a 1D and 2D array is? I haven't seen them mentioned before in this training series.

  • 22nds Avatar

    Just a note. It seems to me that the most popular solutions don't take into consideration that the numbers can be shifted for a lot more than a couple places. Try out the performance of:

    infiniteLoop([[1, 2],[3, 4, 5, 6],[7, 8, 9, 10]], "left", 2000);

    Thanks, @myjinxin2015 for this kata!

  • roaltug Avatar

    I think this kata deserves 6 kyu instead of 7

  • Maryomontes Avatar

    This comment has been hidden.

  • 1KuX Avatar

    It was pretty hard

  • quangnd Avatar

    I don't know how I'm bad at algorithm but I think this kata should be 6 kyu level... :((