Tech Support Guy banner
Status
Not open for further replies.
1 - 1 of 1 Posts

·
Registered
Joined
·
6,693 Posts
Hi cats31,

The object wars is a Scanner instance and therefore, it has no charAt method.
You may replace the line :
letter1= wars.charAt(0);
by
letter1= wars.next().charAt(0);
 
1 - 1 of 1 Posts
Status
Not open for further replies.
Top