Entrega do Desafio #1

Merged
anacarolinaduartecavalcante merged 12 commits from feature/10-longestWords into master 2022-10-28 12:14:06 +00:00
Showing only changes of commit e7ebd59708 - Show all commits

View File

@ -1,4 +1,10 @@
export function sumEven(value) {
// implementar logica aqui
let sumOfEven = 0;
for (let i = 0; i < value.length; i++) {
if (value[i] % 2 === 0) {
sumOfEven = sumOfEven + value[i];
}
}
return sumOfEven;
}