I'd like to know, if using goto ok in such situation? Can you suggest better solution? I see the only one to make second while cicle but then it would be necessary to call "makeMove" two times.
void BoardView::startGame()
{
int currStep=0;
int x,y;
while (board_->isWin()==none)
{
currStep++;
show();
wrong:
std::cout << " Player " << (currStep%2==0 ? 1 : 2) << ": ";
std::cin >> x;
y=x%10;
x/=10;
if (!board_->makeMove(x,y,(currStep%2==0 ? cross : zero)))
{
std::cout << "Wrong move! Try again.\n";
goto wrong;
}
}
}