function sum(arr) { let count=0; arr.forEach(function(x){ count+=x; }) return count; }
function sum(arr) { return arr.reduce((a,b)=>a+b,0); }