2D array problems and matrix algorithms.
- Matrix traversal patterns
- Spiral traversal
- Matrix rotation
- Matrix multiplication
- Searching in sorted matrix
- Dynamic programming on grids
- Path finding in matrix
- Island problems
- Draw the matrix and visualize the pattern
- Watch out for row-major vs column-major order
- Use direction arrays for 4-directional movement: dx[]={-1,1,0,0}, dy[]={0,0,-1,1}
- Many matrix problems reduce to graph problems
- Consider in-place operations to save space