Company: Visa_17sep
Difficulty: medium
Labyrinth Navigation Problem Description Imagine that you're exploring a mysterious labyrinth in the shape of a rectangular matrix, which contains obstacles and teleports. Starting from the upper-left corner, your goal is to reach the lower-right corner by first moving to the right, and then moving down if that doesn't work. You are given integers n and m representing the dimensions of the labyrinth. You are also given obstacles and teleports , which are lists of the cells that contain all the obstacles and teleports, respectively. Details about the labyrinth: An obstacle cannot be traversed - if there's an obstacle in the cell to your right, try moving down. If there are obstacles in the cells to the right and below, stop immediately. A teleport is a pair of cells ( start , end ). If you reach the start cell, you immediately move to the end cell. Note that this doesn't work backwards: you cannot teleport from the end cell to the start cell. It is guaranteed that all teleports have uni