ClosedLab02a author version 20140923 package project03 import java util Random import java util Scanner public class project03a public static void main String args Scanner in new Scanner System in System out println Welcome to Quiz System out print Enter your name String name in next System out println Welcome name Please answer the following questions int scoreCounter 0 int a int b int response a getRandomNum b getRandomNum System out print a b response in nextInt if response a b scoreCounter System out println That is correct else System out println No thats not the right answer its a b a getRandomNum b getRandomNum System out print a b response in nextInt if response a b scoreCounter System out println That is correct else System out println No thats not the right answer its a b a getRandomNum b getRandomNum System out print a b response in nextInt if response a b scoreCounter System out println That is correct else System out println No thats not the right answer its a b a getRandomNum b getRandomNum System out print a b response in nextInt if response a b scoreCounter System out println That is correct else System out println No thats not the right answer its a b System out println You got scoreCounter correct answers System out println Thats scoreCounter 25 in close static int getRandomNum Random rand new Random int a a rand nextInt 20 if a 0 a return a
View Full Document