+ 1

It is not compiling so if anybody know how to solve it then help me.

https://code.sololearn.com/cB1D9h4pSvqj/?ref=app

5th Oct 2023, 1:58 PM
Shaurya Pratap
Shaurya Pratap - avatar
2 Answers
+ 3
Little bit mistake, Java is a case sensitive language so please be careful when you use keyword like 'case' instead of 'Case', 'switch' instead of 'Switch', 'CaseS' not like this 'case 'S' use like this, 'char' instead of 'Char', 'charAt(0)' instead of 'CharAt(0)', hope you understood. Here is your modified code: https://code.sololearn.com/cUtcTOEjS4Ko/?ref=app
5th Oct 2023, 2:13 PM
Sakshi [Offline 🙃]
Sakshi [Offline 🙃] - avatar
+ 1
Here are little tips. 1. Write your code with proper indention. Indentions make it easier to show the block and how they are nested, which in turn easier to debug your code. 2. Keywords show in different color with text editor capable for syntax highlighting. In your case you can notice "Case" and "case" show different colors. If the keyword color doesn’t change then something is wrong about it.
5th Oct 2023, 2:34 PM
Wong Hei Ming
Wong Hei Ming - avatar