Closed ottonascarella closed 7 years ago
Reduce implementation is returning:
return [accumulatedValue];
The javascript implementation of reduce returns only accumulatedValue.
From the exercise description:
Take note this is different from the reduce in ES5, which returns a value instead of an Array!
Reduce implementation is returning:
return [accumulatedValue];
The javascript implementation of reduce returns only accumulatedValue.