challenge-algorithms-v2.0-g.../07-sumEven/index.js

7 lines
159 B
JavaScript

export function sumEven(value) {
// implementar logica aqui
let sums = 0;
value.forEach(item => {
if(item%2==0) sums += item;});
return sums
}