I have created a 2D array and want to print the output. I want to label the columns and rows. I have labeled the rows. but I can not figure out how to label the columns. Something link this:
A B C D E F
Row 1 * * * * * *
Row 2 * * * * * *
Row 3 * * * * * *
Row 4 * * * * * *
Row 5 * * * * * *
Row 6 * * * * * *
Row 7 * * * * * *
Row 8 * * * * * *
Row 9 * * * * * *
Row 10 * * * * * *
Row 11 * * * * * *
Row 12 * * * * * *
Row 13 * * * * * *
Like I said I have the rows and the *, but how do I get the A b c labels on the columns.
for(int i = 1; i < 13; i++)
{
System.out.print("Row " + i + " " );
for(int j = 0; j < 6; j++)
{
System.out.print(seats[i][j] + " ");
}
System.out.println(); //for spacing
}