This week's book giveaway is in the Kotlin forum.
We're giving away four copies of Kotlin in Action and have Dmitry Jemerov & Svetlana Isakova on-line!
See this thread for details.
Win a copy of Kotlin in Action this week in the Kotlin forum!
  • Post Reply Bookmark Topic Watch Topic
  • New Topic

TicTacToeGame  RSS feed

 
Danny Broadwater
Ranch Hand
Posts: 65
Eclipse IDE
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
When I hit  play  I have an error on createBoard and winOrTie. Pleasehelp me with this thank you for your time.   I am using netbeans.

 
Liutauras Vilda
Marshal
Posts: 4638
316
BSD
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
1. It is almost worst code indentation I have seen. You really need to indent your code as nobody else apart from me probably will ever look at it. So fix code indentation and re-post your code.
2. When you get an error, it is useful to tell - what kind of error you're getting? Copy/Paste exactly as the error appears in your NetBeans IDE environment.
3. You said you're getting errors in "createBoard() and winOrTie()", but non of those mentioned methods implementations you showed us. So please do so.
4. Nearly got confused about lines 5 and 6, but it is again down to problem No. 1.
 
Stevens Miller
Bartender
Posts: 1444
30
C++ Java Netbeans IDE Windows
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Liatauras is right, that was originally some very odd formatting. I've reformatted it to how I do it, which is not the only way, but it is an accepted style (known as "Allman" style).
 
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!