Given a grid of `1` (land) and `0` (water), implement `numIslands(grid)` returning the number of islands. Islands connect horizontally or vertically.
Run your code to see results.