def num_sum():
start = int(input("Please specify a starting number: "))
end = int(input("Please specify a ending number: "))
end = end + 1
for x in range(start, end):
num_sum()
Here's an example of what I would like to have happen:
Computer: Please specify a starting number.
User: 1
Computer: Please specify a ending number.
User: 10
Math: 1 + 2 + 3 + 4 + 5 + 6 + 7 + 8 + 9 + 10
Computer: 55
Thanks in advance for the help. It means a lot to me! :)
I've seen a lot of these questions while making this, but a lot of them are very old and messy, I would like to know a new way that is less messy, updated, and less complicated.
For the project I'm doing my code must be non-messy or complicated. (As you can see by my example.)
It should not include any extra modules just plain, simple, beginner python.