← Back to Community
Help
Profile icon
TheMaster7661

hey, this is something i'm trying to do for school. can someone tell me what i'm doing wrong?

Answered by Coder100 [earned 5 cycles]
View Answer
Voters
Profile icon
TheMaster7661
Comments
hotnewtop
Profile icon
Coder100

You forgot to initialize keyboard, add this to your code:

Scanner keyboard = new Scanner(System.in);

or you could just rename the scanner to keyboard :)