feat: criação da resposta do 07-sumEven

This commit is contained in:
Matheus Mariosa 2022-11-02 12:39:28 -03:00
parent c2815674bc
commit de6cd9832d

View File

@ -1,4 +1,10 @@
export function sumEven(value) { export function sumEven(value) {
// implementar logica aqui // implementar logica aqui
var total = 0;
for (let i of value) {
if (i % 2 ===0) {
total += i;
}
}
return total;
} }