Skip to content

error #4

@ghost

Description

Доброго дня. Працював з Вашою книгою Java4Kids на російській мові і знайшов помилку. Потім, думаю, перевірю версію на GitHub і знову побачив, що не вистачає дужки після імені гравця в розгалудженні (виділив жирним):

Розділ 4.7. Repeating Actions with Loops

while (counter< totalPlayers){
counter++;

String thePlayer = players[counter];

if (thePlayer.equals("David")){
continue;
}
System.out.println("Congratulations, "+ thePlayer+ !");
}

Компілятор видає:
Exception in thread "main" java.lang.Error: Unresolved compilation problem:
Syntax error, insert ") Statement" to complete IfStatement

Metadata

Metadata

Assignees

Labels

No labels
No labels

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions