Given a 2d grid of '1's (space clusters with stars) and '0's (dark space clusters without any stars), count the number of galaxies on the grid. An Galaxy is a group a space clusters containing stars, surrounded by dark clusters (no starts) and connected horizontally or vertically.
Examples: