Skip to content

Maple: Sabrina Lauredan #39

Open
SabrinaLauredan wants to merge 1 commit intoAda-C16:masterfrom
SabrinaLauredan:master
Open

Maple: Sabrina Lauredan #39
SabrinaLauredan wants to merge 1 commit intoAda-C16:masterfrom
SabrinaLauredan:master

Conversation

@SabrinaLauredan
Copy link

No description provided.

Copy link

@kyra-patton kyra-patton left a comment

Choose a reason for hiding this comment

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

🐾🐶 Nice work, Sabrina. I'm marking this project as a yellow since the time and space complexity are not filled out and that's something we'd really like you to consider for this project.

Let me know what questions you have.

🟡

Comment on lines 8 to 9
Time Complexity: ?
Space Complexity: ?

Choose a reason for hiding this comment

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

⏱🪐 Time and space complexity?

Comment on lines +18 to +21
if dislikes[0]:
starting_node = 0
else:
starting_node = 1

Choose a reason for hiding this comment

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

🤔Consider an edge case where dislikes contains multiple nodes at the beginning of the adjacency list that are disconnected from the graph. How might you refactor your code to account for this situation?

visited.add(starting_node)
set_a.add(starting_node)

while len(queue) > 0:

Choose a reason for hiding this comment

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

🐩 Nice BFS implementation

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.

2 participants