I have to create a calculator for a small piece of schoolwork and I ask for inputs for the numbers and the symbol that will be used:
number1=int(input("\nWhat is your first number?"))
number2=int(input("\nWhat is your second number?"))
symbol=input("\nWhat is the symbol you will use?")
I want to know if there is any way I can make the int(input())
be asked again if they enter anything apart from an integer.
I'm not really good with Python atm so apologies if I missed something obvious. Also sorry if this thread is a duplicate.