Company: Visa fte
Difficulty: medium
Diagonal Neighbors Let\'s define the diagonal neighbors of a given cell as the surrounding cells, with precisely one corner touching a corner of the given cell. The picture below shows the diagonal neighbors for the cell marked \'A\'. A .grid-visualization { margin: 20px 0; } .game-board { border-collapse: separate; border-spacing: 2px; } .game-board td { width: 40px; height: 40px; border: 1px solid #000; text-align: center; vertical-align: middle; } .diagonal { background-color: #20B2AA; } .center { font-weight: bold; } Input Format A matrix representing the grid and a position marking cell \'A\'. Output Format Return the positions of all diagonal neighbors for the given cell. Constraints The grid is at least 3x3 in size The given cell position is valid within the grid All diagonal neighbors must be within the grid boundaries Example For the cell marked \'A\' in the visualization: The diagonal neighbors are shown in turquoise color There are 4 diagonal neighbors in total Each diagonal