Basically, I am creating this game which consists of the user answering some multiple choice questions. I want it so when the user gets the answer wrong once, they try again and if they get the answer wrong twice, the correct answer shows up. But right now, if the user gets the answer wrong, it skips to the next question. How can I do this? Any help is appreciated. Here is my code:
score = 0
def correct():
print("Congratulations! You got a point!")
global score
score = score + 1
print("Points: ",score)
def incorrect():
print("Wrong, try again!")
print("Points: ",score)
def question(q,a):
print(q)
answer = input("Answer: ")
if answer == a:
correct()
else:
incorrect()
question("What is the capital city of England?\n a. London\n b. Paris\n c. York", 'a')
question("What is the capital city of France?\n a. Rome\n b. Paris\n c. Jersey", 'b')
question("What is the capital city of Germany?\n a. Accra\n b. Weimar\n c. Berlin", 'c')
question("What is the capital city of The Netherlands?\n a. Moscow\n b. Amsterdam\n c. Cape Town", 'b')