Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- for (int i = 0; i < questions.length; i++) {
- answer = JOptionPane.showInputDialog(questions[i][0]);
- if (answer.equalsIgnoreCase(questions[i][1])) {
- JOptionPane.showMessageDialog(null, "Correct!");
- score++;
- }
- else {
- JOptionPane.showMessageDialog(null, "Incorrect!");
- score--;
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement