Answers for "Adding all input numbers"

0

Adding all input numbers

# try block to handle the exception
try:
    my_list = []

    while True:
        my_list.append(int(input()))

# if the input is not-integer, just print the list
except:
    print('Please Enter A Number')

print(sum(my_list))
Posted by: Guest on August-05-2021

Code answers related to "Adding all input numbers"

Python Answers by Framework

Browse Popular Code Answers by Language