An open API service indexing awesome lists of open source software.

https://github.com/jackhowa/slasher-flick

Return the remaining elements of an array after chopping off n elements from the head.
https://github.com/jackhowa/slasher-flick

algorithm freecodecamp javascript

Last synced: 9 months ago
JSON representation

Return the remaining elements of an array after chopping off n elements from the head.

Awesome Lists containing this project

README

          

# Slasher Flick
Return the remaining elements of an array after chopping off n elements from the head.

The head means the beginning of the array, or the zeroth index.

## Solution
I used slice to begin at the howMany point. In this way, I didn't really need to delete from the head, or start, of the array.

https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Array/slice