Skip to content

Instantly share code, notes, and snippets.

@vmussak
Created April 14, 2018 15:03
Show Gist options
  • Save vmussak/5ea46f66e4c3ef8ef48e2f60c0c6f757 to your computer and use it in GitHub Desktop.
Save vmussak/5ea46f66e4c3ef8ef48e2f60c0c6f757 to your computer and use it in GitHub Desktop.
var lstInt = [1, 2, 3, 4, 5];
var soma = 0;
for(var i = 0; i < lstInt.length; i++) {
soma = soma + lstInt[i];
}
console.log(soma); //15
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment