Number of Islands
Medium
Graphs
Given an R x C grid of '1' (land) and '0' (water), count the islands. An island is a group of horizontally or vertically connected land cells.
Constraints
1 <= R, C <= 300
Discussion
No discussions yet.
Join Shalyam Newsletter
Get exclusive insights with every issue: education, research and innovation news.
Shalyam Support
Hi! Ask us anything โ we'll reply on WhatsApp or Telegram within 24 hours.