forked from M3-Academy/challenge-algorithms-v2.0
feat: 06-sum
This commit is contained in:
parent
df485c8387
commit
85e50ecc66
@ -1,4 +1,9 @@
|
||||
export function sum(values) {
|
||||
// implementar logica aqui
|
||||
|
||||
var sum = values;
|
||||
var soma = 0;
|
||||
for (let i = 0; i < sum.length; i++) {
|
||||
soma += sum[i]
|
||||
}
|
||||
return soma;
|
||||
}
|
Loading…
Reference in New Issue
Block a user