I don't understand why my Javas witch statement won't work & possibility of cases other than numbers in switch statements
Hello guys, I wrote a switch statement (see below), and as far as I can tell, it's written correctly so I don't understand what I did wrong, even with the explanation of the error that comes up. Like I think the error is saying that a semicolon should go between the closing parentheses or ")"and the opening squiggly brace or "{" in the first line of the switch statement, but a ; shouldn't go there. The 2nd error is an orphaned case, but I don't know what that means. And while I'm here, can you have a case that is anything other than a number? Like: switch (tagger) { case ana: System.out.println("Ana is it."); Below are the code, the errors and a link to the code. First the code: public class Program { public static void main(String[] args) { int medal = 1; Switch (medal) { case 1: System.out.println("You got 1st place."); case 2: System.out.println("You got 2nd place."); case 2: System.out.println("You got 3rd place"); } } } Next the Errors: ./Playground/Program.java:10: error: ';' expected Switch (medal) { ^ ./Playground/Program.java:11: error: orphaned case case 1: ^ 2 errors Link to the code: https://code.sololearn.com/cBOSiaYx4nFe Thank you in advance for your help! Thanks, Iulia