Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Number of Islands _ DFS.cpp #6740

Open
wants to merge 3 commits into
base: master
Choose a base branch
from

Conversation

RuchNas-Pottah
Copy link

This contains an accepted solution to the problem 'Number of Islands' on LeetCode, done with the help of the Depth-First-Search algorithm.

Fixes issue:
Added a concise and easily understandable code for the problem.

Changes:
Made the code understandable, used DFS, and followed a proper breakdown of functions.

This contains an accepted solution to the problem 'Number of Islands' on LeetCode, done with the help of the Depth-First-Search algorithm.
Copy link
Member

@AdiChat AdiChat left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Embed a sample input in the code or explain the input format in comments with examples.

Input format explained in the comments
@RuchNas-Pottah
Copy link
Author

RuchNas-Pottah commented Oct 14, 2023

Sir, I have updated the code with an explanation of the sample input.

Copy link
Member

@AdiChat AdiChat left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Include the complete code with main() function which one can run on terminal.

Added main function and the whole program can be run in the terminal now.
@RuchNas-Pottah
Copy link
Author

Include the complete code with main() function which one can run on terminal.

Sir, I have updated the complete code with the main() function that runs in the terminal.

@RuchNas-Pottah
Copy link
Author

@AdiChat Sir please review my updated pull request

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants