Apr-16-2017, 06:17 AM
This program works very well with C++. I think it should be the same with python3. I modified a little my code Here thenew
# file4.py import sys def getvalue(value, sum): value=input("enter the value ") print("value entered : ", value) #if input=CR then return sum += value#put value into sum, (apparently correct for only integers) print("sum", sum) return ;#value; size=40 print("here is the addition of many numers (even with a .) Maximum of numbers=",size) print("once you have finished your list of numbers, just press ENTER to indicate the end\n") sum=0.0 value=0.0 count=1 while (count != 0): getvalue(0,0) count=count +1