Algorithm · Uber · Medium
This problem set contains three independent tasks. Implement each requested function and state its worst-case time and space complexity. Tasks 2 and 3 use the same telephone keypad mapping. Task 1: Count Connected Land Regions You are given a binary matrix grid. A cell containing 1 is land, and a cell containing 0 is water. A land region is a maximal group of land cells where any two cells can be reached from each other by moving only up, down, left, or right through land…
Checking your access…