mirror of
https://github.com/coding-horror/basic-computer-games.git
synced 2025-12-22 15:16:33 -08:00
added getChar method
This commit is contained in:
@@ -73,4 +73,15 @@ public class HighIQ {
|
|||||||
public void printBoard() {
|
public void printBoard() {
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
private char getChar(int position) {
|
||||||
|
Boolean value = board.get(position);
|
||||||
|
if(value == null) {
|
||||||
|
return ' ';
|
||||||
|
} else if(value) {
|
||||||
|
return '!';
|
||||||
|
} else {
|
||||||
|
return 'O';
|
||||||
|
}
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user