Skip to content

nathanfaucett/js-array-reduce

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

2 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

array-reduce

applies a function against an accumulator and each value of the array (from left-to-right) to reduce it to a single value.

var arrayReduce = require("@nathanfaucett/array-reduce");


arrayReduce([0, 1, 2, 3, 4], function(currentValue, value) {
    return currentValue + value;
}) === 10;

About

array reduce for the browser and node.js

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published