Current location - Recipe Complete Network - Complete cookbook of home-style dishes - Hello, my switch function selected and executed the case 1, and then I want to return to the main menu and select another case. How to do it?
Hello, my switch function selected and executed the case 1, and then I want to return to the main menu and select another case. How to do it?
Two situations:

1. If you just want to continue to selectively execute the following case, don't break it after case 1 is executed.

2. If you want to choose to execute the above cases without adjusting the case order, please use goto statement or recursively design the re-entry switch.

hope this helps