I'm a beginner at Java programming and I was wondering if anyone could help / explain how to use a while loop in a task. The task is to create a menu which is appears constantly after the user has made an input. The user should enter instructions in the form of the numbers 1 to 4 as follows:
1 - Reroll the dice
2-get the value
Once the user has entered a number and an instruction is made the menu must re-appear asking the user to make a choice again. This must happen repeatedly
User enters: 4
Program displays: "The minimum value is: n"
Then the menu reappears asking the user to make another choice
I understand I need to use a while loop (and maybe a switch) but I’m unsure how to make this happen.
I'm not really good at explaining things so I apologize if anything is unclear or just confusing.