Skip to content

Instantly share code, notes, and snippets.

@parzibyte
Created October 11, 2020 00:01
Show Gist options
  • Save parzibyte/12ffb30e4a11ea2d006512fdf675c1ea to your computer and use it in GitHub Desktop.
Save parzibyte/12ffb30e4a11ea2d006512fdf675c1ea to your computer and use it in GitHub Desktop.
arreglo = [10, 7, 6, 10, 4, 9, 10, 5, 9, 8, 4, 3, 1, 10, 10, 10, 2]
# Para sumar simplemente recorremos el arreglo y aumentamos el valor
suma = 0
for valor in arreglo:
suma = suma + valor
print(f"La suma es {suma}")
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment