0
In python what is the error in my code
while True : print("enter 'add' to add two numbers") print("enter 'subtract' to subtract two numbers") print("enter 'quit' to end the program") user_input=input(": ") if: user_input=="quit": break elif: user_input=="add": num1 =float(input("enter a number:")) num2 =float(input("enter second number:")) result=str(num1+num2) print(result) elif: user_input=="subtract": num1 =float(input("enter a number:")) num2 =float(input("enter second number:")) result=str(num1-num2) print(result) else: print("unknown inpu
1 Answer
0
There alot of issues review the elif and if statements,indent well and close all brackets