公共靜態無效的主要(字串[] args){
//初始化遊戲板
initGame();
//start the game
do {
PlayerMove(Cplayer);
updategame(Cplayer, crow, ccol);
printboard();
//game over message
if (currentstate == you_win){
System.out.println("'X' Won!!");
else if (currentstate == comp_win)
System.out.println("'O' won!!");
else if (currentstate == draw)
System.out.println("It's a Draw :(");
}
你的花括號中不以網格的方式設置你的預期的活動。如果和其他人應該在同一水平。 – Compass
請更好格式化? 'do {}'? – Aryan
什麼數據類型是'currentstate','you_win','draw'和'comp_win'?他們不是絃樂隊嗎? –