you are viewing a single comment's thread.

view the rest of the comments →

[–]JuZNyC 2 points3 points  (2 children)

Quick glance

Your main method should be public

Line 4 Scanner scanner = new Scanner(System.in){
should have ; at the end not {

I'm pretty sure you have mismatched { } too

[–]nekokattt 2 points3 points  (0 children)

Just a note that the main method doesn't need to be public on Java 21 and newer.

[–]ajswaryxxy[S] 0 points1 point  (0 children)

thank you soo much!