Microsoft Interview Question

2D array battleship leetcode question