Question: def is_sink(elevation_map: List [List [int]], cell: List [int]) -> bool: Return True if and only if cell exists in the elevation map elevation_map and cell

def is_sink(elevation_map: List [List [int]],
def is_sink(elevation_map: List [List [int]], cell: List [int]) -> bool: "Return True if and only if cell exists in the elevation map elevation_map and cell is a sink. Precondition: elevation_map is a valid elevation map. cell is a 2-element list. >>> is_sink (THREE_BY_THREE, [0, 5]) False >>> is_sink (THREE_BY_THREE, [0, 2]) True >> > is_sink (THREE_BY_THREE, [1, 1]) False 3> > is_sink (FOUR_BY_FOUR, [2, 3]) True 3> > is_sink (FOUR_BY_FOUR, [3, 2]) True >>> is_sink (FOUR_BY_FOUR, [1, 3]) False

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Mathematics Questions!