OpenGenus / cosmos

World's largest Contributor driven code dataset | Used in Quark Search Engine, @OpenGenus IQ, OpenGenus Visual Project

Home Page:http://internship.opengenus.org

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Number of Islands using DFS [Hacktoberfest]

harshagrawal523 opened this issue · comments

This is a(n):

  • New algorithm
  • Update to an existing algorithm
  • Error
  • Proposal to the Repository

Details:
Given an m x n 2D binary grid grid which represents a map of '1's (land) and '0's (water), return the number of islands.

An island is surrounded by water and is formed by connecting adjacent lands horizontally or vertically. You may assume all four edges of the grid are all surrounded by water.

@AdiChat Please accept the issue with hacktober tag and review my PR here

Hey @OpenGenus I want to add an efficient approach to your problem. Can you please assign this to me.