Grade 12 Computer Science · Two-dimensional arrays

Common mistakes with grids

The four mistakes stemming from forgetting a row is an array.

Four mistakes, and three of them are one

Swapping the two positions, asking about a length in the wrong place, assuming every row is equal. Three mistakes that look entirely different, and yet one picture in your head prevents all three. And the fourth, the quietest of all, does not come from it at all. What is the picture?

Three of the four mistakes below vanish the moment the picture from the first lesson is held in mind: there is no grid, there is an array whose items are arrays. The fourth belongs to the neighbour pattern.

The first three groups come from the same picture: an array whose every item is an array.