Given the following code (see below) how do you make it sothat only y lets you s
ID: 3613048 • Letter: G
Question
Given the following code (see below) how do you make it sothat only y lets you start another calender and enter month, etc.,while n ends the program. Otherwise it just asks the questionagain.------------ Relevant section of code:
System.out.print("Would you like another (y/n)? "); another=stdIn.next().charAt(0); }while(another!='Y'&& another=='y'); Given the following code (see below) how do you make it sothat only y lets you start another calender and enter month, etc.,while n ends the program. Otherwise it just asks the questionagain.
------------ Relevant section of code:
System.out.print("Would you like another (y/n)? "); another=stdIn.next().charAt(0); }while(another!='Y'&& another=='y');