Will the logic start at the bottom and work towards the top
or will it start at the top and work towards the bottom?
Ok, what are the details for that? The computer does not understand...
Type: Posts; User: Norm
Will the logic start at the bottom and work towards the top
or will it start at the top and work towards the bottom?
Ok, what are the details for that? The computer does not understand...
You need to work out the logic before writing code.
What if there is already an "R" in the bottom row?
Yes. That is the usual way to write programs - create methods for jobs that are done...
Create a method that prints the array.
Then call it whenever the array has been changed.
theArray[row][column] = theValue;
theArray - the name of the array
row - the row index (an int)
column - the column index (an int)
= - an assignment statement
theValue - the value to be assigned...
That is confusing.
For me: Rows are horizontal (left, right) and columns are vertical(up, down).
There isn't a bottom column of a row. There is a bottom row of a column.
I don't understand how a user picking a row puts a value in a column. How does the program pick the column?
The bottom display of a filled in grid in post#2 shows the "R"s in column 4 not in row...
Did you mean column?
Ok, I think I understand. What problems are you having placing the "R" in the array?
Can you explain how a user input of "4" can be used to place an "R" at a specific row and column in a 2 dim array?
Please explain how the row and column for placing the "R" is computed?