Skip to content

2-D arrays: working with a grid

Handout

A grid of boxes

  • A 2-D array is a grid: rows and columns of the same type.
  • int g[2][3]; makes 2 rows and 3 columns — 6 ints in all.
  • You reach one cell with two indexes: g[row][col].

Handout

Log in or create account

IGCSE & A-Level