Mental Model
We find groups of connected land cells by exploring neighbors until no new land is found, counting each group as one island.
Analogy: Imagine a map with patches of forest (land) separated by rivers (water). We walk through each forest patch fully before moving to the next, counting how many separate forests there are.
Grid example: 1 1 0 0 0 1 1 0 0 0 0 0 1 0 0 0 0 0 1 1 1 = land, 0 = water
