When trying to run this simple calculator with only addition and passing "1 + 2" in the terminal without quotes
numbers=["1","2","3","4","5","6","7","8","9"]
str=input()
numlist = str.split()
for i in range(len(numlist)):
number=""
operate=""
for j in numlist[i]:
if j in numbers:
number=number+j
else:
operate=operate+j
if operate == "+":
sum = 0
for i in range(len(numlist)):
sum = sum + int(number)
it results In this
Exception has occurred: ValueError
invalid literal for int() with base 10: ''
File "C:\Users\dummy\Desktop\New Text Document.py", line 15, in <module>
sum = sum + int(number)
```'
Any help would be appreciated