Ad

a simple python calculator with the four primary processes/functions. can only support two numbers

#simple calculator witha all functions

function = 'add'
number1 = 2
number2 = 8



if function == 'add':
    sum = number1 + number2
    print(sum)
    
elif function == 'substract' or 'minus':
    diff = number1 - number2
    print(diff)
    
elif function == 'multiply':
    product = number1 * number2
    print(product)
    
elif function =='divide':
    answer = number1 / number2
    print(answer)
    
else:
    print('No related function')