‘Complete the following:’ Scanner kb = new Scanner(System.in); int choice = 0; d
ID: 3698280 • Letter: #
Question
‘Complete the following:’
Scanner kb = new Scanner(System.in); int choice = 0; do{ System.out.println(" Please choose "); System.out.println("1. Do this"); System.out.println("2. Do that"); System.out.println("3. Do the other thing"); System.out.println("4. Quit"); System.out.print("Enter option--> "); choice = kb.nextInt(); kb.nextLine(); switch (_________) { ___________: System.out.print("You selected option 1"); ____________; ___________: System.out.print("You selected option 2"); ____________; ___________: System.out.print("You selected option 3"); ____________; ___________:
Explanation / Answer
1.choice
2.case 1:
3.break;
4.case 2:
5.break;
6.case 3:
7.break;
8.case 4:
Related Questions
Navigate
Integrity-first tutoring: explanations and feedback only — we do not complete graded work. Learn more.