Python grid and matrix problems
Walk, fill and search rows and columns of 2D data in Python, on problems with tests.
Beginner
Intermediate
- 273. Minesweeper NumbersCount the mines hiding around every square of the board60 XP12 min
- 278. Zero Out Rows and ColumnsOne failed sensor spoils its whole row and column60 XP10 min
- 284. Paint Bucket FillThe paint bucket tool of a drawing program, from the inside65 XP14 min
- 288. Saddle PointsSpots on a map shaped like the middle of a saddle65 XP12 min
- 309. Search a Sorted GridRows in order, columns in order: where is the number hiding?70 XP12 min
Advanced
- 351. Largest Square Solar PanelThe biggest square solar panel that fits on a patchy roof120 XP25 min
- 354. Robot Across the WarehouseThe quickest way across a warehouse floor, diagonals allowed120 XP25 min
- 376. Largest Plus-Shaped Flower BedLay out the biggest plus-shaped flower bed on a rocky plot135 XP28 min
Expert
- 445. Knight on an Endless BoardA chess knight on a board that never ends: how quickly can it get there?220 XP45 min
- 449. Sledgehammer MazeA sledgehammer with a few swings left: how fast can you cross the maze?220 XP40 min
- 485. Count the Rugs That FitA floor with cracked tiles: how many rectangular rugs fit on the good ones?260 XP55 min
- 493. Rain on a Height MapRain pools in the hollows of a blocky landscape: how much stays?270 XP55 min
Other topics
- Python Basics
- Strings
- Lists
- Dictionaries and sets
- Loops
- Functions
- Math
- Sorting and searching
- Two pointers
- Sliding window
- Stacks and queues
- Recursion and backtracking
- Dynamic programming
- Greedy
- Graphs
- Trees
- Bit manipulation
- Classes
- Iterators and generators
- Parsing
- Simulation
- Python idioms
- Regular expressions
- Codes and ciphers
- Working with data
- Geometry
- Games and puzzles
- Heaps
- Data structures
Or see every challenge, with study plans, today's challenge and duels.