export the function isArray
that should return true if the given value is
a an array
export the function argsToArray3
that takes 3 arguments and return an array of
the 3 given values
export the function first
that takes an array and return the first value
export the function last
that takes an array and return the last value
export the function each
that similarly to
Array.prototype.forEach
but you don't have to handle the this
argument and you should iterate over
empty elements and uses an additional last argument which is the array to
iterate over:
const arr = [ 1, 2, 3 ]
// Were we would use the method like so :
arr.forEach(console.log)
// We should be able to use your functions as such :
each(console.log, arr)
Sames as each
but for
Array.prototype.filter
Sames as each
but for
Array.prototype.map
Sames as each
but for
Array.prototype.reduce