javascript-questions
javascript-questions copied to clipboard
Answer of question 65 is incorrect
The first argument that the
reduce
method receives is the accumulator,x
in this case. The second argument is the current value,y
. With the reduce method, we execute a callback function on every element in the array, which could ultimately result in one single value.
The first argument of the reduce
method is not the accumulator. The first argument of the reduce
method is a callback
function, also called a reducer function. The first argument of the reducer function, which takes four arguments, is the accumulator,
Can I work on this issue? @jakeherp @Tarabass