Company: Flipkart_4aug
Difficulty: medium
Wizard Chess Escape Problem Description Harry is being chased by an unknown enemy while trying to get to the Philosopher's stone to a safe place. He stands on one corner of a giant wizard chess board with the door to escape being at the diagonally opposite end of the board. Wizard chess boards are always square in shape, and allow anyone to move only one step at a time in any of the four directions: forward, backward, left & right. Some blocks on the board have the mark of Voldemort, and if Harry steps on any of those blocks, he will instantly die. Harry is standing at the top-left corner block of the board, and the door is at the bottom right corner block. To avoid capture, Harry needs to get to the escape door as quickly as possible. Help Harry in his quest by writing a program to find out the least number of steps needed to reach the escape door. Make the code as efficient as possible (in terms of time complexity), and print the least number of steps required as output. Read the inp