freeCodeCamp / wiki

freeCodeCamp's deprecated wiki articles
http://www.freecodecamp.com/wiki
281 stars 308 forks source link

Slasher Intermediate explanation has incorrect statement regarding slice() #1208

Open raisedadead opened 8 years ago

raisedadead commented 8 years ago

Refers : https://github.com/FreeCodeCamp/FreeCodeCamp/issues/9501

by @wiseleo:

Someone apparently copied the explanation from splice.

Modify the array with slice() and return it.

Slice does not modify arrays.

The slice() method returns a shallow copy of a portion of an array into a new array object. - Source: MDN

The entire explanation is problematic:

Rafase282 commented 8 years ago

The changed can be done here http://forum.freecodecamp.com/t/algorithm-slasher-flick/16047