Page 1 of 1
Consider the following program segment: Scanner input new Scanner(System.in); System.out.print("Please enter your score"
Posted: Thu Jun 02, 2022 8:18 am
by answerhappygod

- Consider The Following Program Segment Scanner Input New Scanner System In System Out Print Please Enter Your Score 1 (20.05 KiB) Viewed 12 times

- Consider The Following Program Segment Scanner Input New Scanner System In System Out Print Please Enter Your Score 2 (35.14 KiB) Viewed 12 times
Consider the following program segment: Scanner input new Scanner(System.in); System.out.print("Please enter your score"); int value input.nextInt(): if (value> 90 ) ( System.out.println("well done"); } else if ( value 75) ( System.out.println("satisfactory my child"); } else ( System.out.println("stay positive");: ( What is the output of the given program if the user enters 100? A. Well done B. Well done satisfactory my child stay positive C. stay positive
Consider the following program segment: Scanner input = new Scanner(System.in); System.out.print("Please enter your score"); int value input.nextInt(); if (value> 90 ) { System.out.println("Well done"); } else { if (value >= 75 ) { System.out.println("satisfactory my child"); } else { System.out.println("stay positive"); }