Hello I am trying to generate a random case to be used to display a string. So far the code below will only output case 2. For example, if the randomNum was 1, I would like it to print out what is in case 1, and if the randomNum was 2, I would like it to print out what is in case 2. Please let me know if this is possible or not, and show me how I can correct my code if it is possible. Thank you for your help!
String Aries = "";
Random number = new Random();
int i = 0;
int randomNum = number.nextInt(2) + 1;
switch(randomNum)
{
case 1:
Aries = "On April 2...";
case 2:
Aries = "In 2018...";
}
System.out.println(Aries);