0

How may I input numbers in this code to be add up (sum) ?

Recently I started learning Python, would you please let me know how may I input numbers to be be Add up (sum) in this code ? I use Spyder IDE , in IN/OUT page (in IPython part) may I input various numbers ? how ? https://code.sololearn.com/cIhzfUug0H5v/?ref=app

7th Dec 2017, 1:48 PM
NIMA
NIMA - avatar
3 Réponses
+ 1
https://code.sololearn.com/cQ10zXrDacp4/?ref=app
7th Dec 2017, 5:04 PM
Falko
Falko - avatar
+ 1
solved 👍
7th Dec 2017, 8:39 PM
NIMA
NIMA - avatar
0
so far, you only defined a function to calculate the sum. now you need to call the function, for example like this: my_sum=_find_sum_sample_([1,2,3,4,5]) print(my_sum) just add these two lines at the end of your code, and 15 will be the output, because the list [1,2,3,4,5] is given as input. you can input any other list that you like instead 😊
7th Dec 2017, 4:58 PM
Falko
Falko - avatar