Learn practical skills, build real-world projects, and advance your career

DSA Course Project - Count the Islands using DFS

Assignment 4 - Final Course Project for jovian.ai Data Structures and Algorithms in Python course

https://jovian.ai/learn/data-structures-and-algorithms-in-python

This notebook solves the following problem using Depth First Search:

Given a boolean 2D matrix, find the number of islands. A group of connected 1s forms an island.

Source: https://www.geeksforgeeks.org/find-number-of-islands/

project_name = 'Count the Islands using DFS' # give it an appropriate name
!pip install jovian --upgrade --quiet
import jovian
from timeit import default_timer as timer
from textwrap import dedent
import math
jovian.commit(project=project_name)
[jovian] Detected Colab notebook... [jovian] Uploading colab notebook to Jovian... [jovian] Capturing environment.. [jovian] Committed successfully! https://jovian.ai/gtaljaard/count-the-islands-using-dfs