Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR JAVASCRIPT

js reduce

let newArray = array.reduce( (acc, element, index, originalArray) => {
    // return acc += element
}, initialValue)
Source by my.learn.co #
 
PREVIOUS NEXT
Tagged: #js #reduce
ADD COMMENT
Topic
Name
3+7 =