Guided lesson

Matrices and Grids

Linear Data Structures

Matrices and Grids

Core

Mental model

  • Use row and column indexes.

Operations

read cell O(1)

Cost shape

Full scan O(R*C)

Watch out

Swapping row and column.

Related algorithms

BFSDFSDynamic Programming
Guided progression
10% lesson
Step 1 / 2Learner goal
Speech settings Speed 1.0 · Volume 90%

Keyboard: Space play/pause · Arrow keys step · Page Up/Down change sections · R restart