Convert the do-while loop in the following code segment to a while loop: Scanner keyboard = new Scanner(System.in); String input; char sure; do { System.out.print("Are you sure you want to quit?...



Convert the do-while loop in the following code segment to a while loop:


Scanner keyboard = new Scanner(System.in);


String input;


char sure;



do



{



System.out.print("Are you sure you want to quit? ");



input = keyboard.next();



sure = input.charAt(0);


} while (sure ! = ' Y' && sure ! = ' N');

Nov 19, 2021
SOLUTION.PDF

Get Answer To This Question

Related Questions & Answers

More Questions »

Submit New Assignment

Copy and Paste Your Assignment Here