diff --git a/07-sumEven/index.js b/07-sumEven/index.js index bb1e095..3ff263d 100644 --- a/07-sumEven/index.js +++ b/07-sumEven/index.js @@ -1,4 +1,14 @@ export function sumEven(value) { // implementar logica aqui - + let soma = 0; + for (let number of value) { + if (value.length === 0) { + return 0; + } else + + if (number % 2 === 0) { + soma = soma += number; + } + } + return soma; } \ No newline at end of file