Module 9 · Arrays
Two Dimensional Arrays and the Grid
Free with an accountReading
Kenji keeps his chess board in one array of 64 boxes. To find row 3, column 5, he works out 3 x 8 + 5 in his head. He says one long array is faster. He has also made it 27, twice in one game.
Sign in to read
This lesson is free, with an account
An account costs nothing and opens every lesson in this track that is not marked Pro, on every device you read on.
What is inside Two Dimensional Arrays and the Grid
- A grid is an array of rows
- The nested walk, row by row
- Short rows and the zero-fill rule
- Reading a grid and summing each row
- The two diagonals of a square grid
- Transposing a square grid in place
- One long line of boxes