fixed a typo...

Signed-off-by: Alex A. Naanou <alex.nanou@gmail.com>
This commit is contained in:
Alex A. Naanou 2018-09-30 01:59:57 +03:00
parent 1f6b2a0f69
commit b28589d13c

View File

@ -63,7 +63,7 @@ And for *flat* lists `.reduce(..)` and friends are simpler and more logical. `wa
// sum the items in a *deep* array (depth-first)...
var sum = walk(function(r, n, next){
return n instanceof Array ?
next('queue', r, ...n)
next('do', r, ...n)
: r + n }, 0)
sum( [1, [2, 3], 4, [[5], 6]] ) // -> 21