Boundary flood fill [mp]
Micro pattern¶
Description¶
Flood from boundaries to identify protected or excluded components before processing the complement.
Problems¶
- 130. Surrounded Regions (Top Hard)
- 1020. Number of Enclaves (Graph Theory)
- 1254. Number of Closed Islands (Graph Theory)
- 417. Pacific Atlantic Water Flow (Graph Theory)