I am trying to quit a python program with either "q" or "Q" but when I put in "Q" it give an error message about the syntax being incorrect.
else:
print("That was an invalid response. Enter a number or 'q' to quit.")
# <<Check correctness of user's response>>
if response == 'q''Q':
keep_asking_questions = False
I tried replacing if response == 'q''Q': and if response == 'q,Q':
none worked.