#1 Jozef Vrana
public Field(int rowCount, int columnCount, int mineCount) {
this.rowCount = rowCount;
this.columnCount = columnCount;
this.mineCount = mineCount;
tiles = new Tile[rowCount][columnCount];
generate();
}
public void update() {
int row, column;
System.out.println(" 0 1 2 3 4 5 6 7 8");
for (row=0; row < field.getRowCount(); row++) {
switch(row){
case 0:System.out.print("A ");break;
case 1:System.out.print("B ");break;
case 2:System.out.print("C ");break;
case 3:System.out.print("D ");break;
case 4:System.out.print("E ");break;
case 5:System.out.print("F ");break;
case 6:System.out.print("G ");break;
case 7:System.out.print("H ");break;
case 8:System.out.print("I ");break;
}
for (column=0; column < field.getColumnCount() ; column++) {
System.out.print(" ");
System.out.print(field[row][column]);
}
System.out.println();
}
}
}