pieces = input('Enter numbers: ').split() # list of strings print('Their sum is', sum(int(p) for p in pieces))