/CS-1102

Primary LanguageJava

CS-1102

A simple quiz code snippet that asks the user to answer a multiple choice question

The program checks if the user chose an asnwer from the available choices and throws an error if not

The correct answer is hardcoded in the program and the program checks the user's answer against the preprogrammed answer

If it is correct, it shows a "Correct" dialog, and exits upon clicking okay

If not correct, it shows "Incorrect..." for any answer in the choices provided or "Invalid..." for a different answer and asks the question again.