From 89c3e0852a0052d80f7293040d8d49e323addbe3 Mon Sep 17 00:00:00 2001 From: Douglas Nobrega Date: Fri, 28 Oct 2022 18:36:45 -0300 Subject: [PATCH] desafio 06-concluido --- 06-sum/index.js | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/06-sum/index.js b/06-sum/index.js index ebc2ee1..55b04fb 100644 --- a/06-sum/index.js +++ b/06-sum/index.js @@ -1,4 +1,9 @@ export function sum(values) { // implementar logica aqui - + let soma = 0 + + for(let i = 0; i < values.length; i++) { + soma += values[i]; + } + return soma; } \ No newline at end of file