I am trying to only return a value if the user inputs a or b but regardless of what I input I can never get to the else statement to return the input. It continuously calls the function. Is there a better way to do this?
def display_menu():
print(f"Conversions Menu:\na. Feet to Meters\nb. Meters to Feet")
usrInput=input(f"Select a converions(a/b): ").lower()
if usrInput != "a" or "b":
print("failed")
print(f"please enter a or b")
display_menu()
else:
return(usrInput)