Find all cells in a 2D matrix where rainwater can flow to both the Pacific Ocean (left and top edges) and Atlantic Ocean (right and bottom edges), where water flows from higher or equal height cells to lower or equal height cells.
Markdown supported · ⌘↵ to post
No responses yet.