Question: Hello C# question: I am making a simple 10 question true or false, and multiple-choice quiz. Incorrect answers get displayed again at the end of
Hello C# question:
I am making a simple 10 question true or false, and multiple-choice quiz. Incorrect answers get displayed again at the end of the quiz to be attempted again. Right not it is stuck in an infinite loop as long as it is answered incorrectly it will keep asking the question. I need it to stop after just 1 reattempt how do I do this?

//This shows the incorrect answers again in the order they appeared for (int i = 0; i
//Display options Console.WriteLine(options[incorrectanswers[i]]);
//Ask user to answer question again
//Retry is used when anything else besides a valid input is made to the console ie: not A, B, C, D, True or False Retry: Console.WriteLine("Pleae choose the correct answer"); Console.WriteLine("Please enter a valid input: A, B, C, D, True or False."); var answer = Console.ReadLine();
//This will verify the answer if (verifyanswer(answer)) { if (answer == answers[incorrectanswers[i]]) { correct = correct + 1; Console.WriteLine("Correct!"); }
//This will happen if the answer is incorrect a second time else { incorrectanswers.Add(incorrectanswers[i]); Console.WriteLine("Incorrect."); } } //If an invalid entry is input into the console it will go to the Retry script else { goto Retry; }
Thank you!
//This shows the incorrect answers again in the order they appeared for (int i = 0; i
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
