2 ms·
Eliminating the map, named functions or not, makes it pretty clear: var r = array.reduce((total, num) => total + (num * num), 0);
by jasonkostempski 9y ago
Eliminating the map, named functions or not, makes it pretty clear:
var r = array.reduce((total, num) => total + (num * num), 0);