feat: Resolve o exercício 07-sumEven
This commit is contained in:
parent
c29171035f
commit
bd7262fc36
@ -1,4 +1,10 @@
|
||||
export function sumEven(value) {
|
||||
// implementar logica aqui
|
||||
|
||||
let add = 0
|
||||
for (let i = 0; i < value.length; i++) {
|
||||
if (value[i] % 2 === 0) {
|
||||
add = add + value[i]
|
||||
}
|
||||
}
|
||||
return add
|
||||
}
|
Loading…
Reference in New Issue
Block a user