This is the development of a very simple calculator program in python.

def add():
answer = (num1) + (num2)
print(answer)
def divide():
answer = (num1) / (num2)
print(answer)
def times():
answer = (num1) * (num2)
print(answer)
def subtract():
answer = (num1) - (num2)
print(answer)
print("Welcome to the calculator! ")
num1 = int(input("Please enter a number "))
num2 = int(input("Please enter another number "))
user = input("What operation would you like to do? ")
if user == "add":
add()
elif user == "subtract":
subtract()
elif user == "divide":
divide()
elif user =="times":
times()
else:
print("Error!")
exit()
This was my first draft of a calculator however, it is only limited to two numbers as indicated by the variables num1 and num2. Also, it is limited to the four functions (add, subtract, times and divide)
The add function adds both the variables num1 and num2.
The subtract function subtracts both the variables num1 and num2.
The times function times both the variables num1 and num2.
The divide function divides both the variables num1 and num2
This will be updated and improved in the future.