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

Angela #6

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open

Angela #6

wants to merge 1 commit into from

Conversation

AngelaOh
Copy link

@AngelaOh AngelaOh commented Sep 2, 2019

No description provided.

Copy link

@CheezItMan CheezItMan 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 Angela! You hit all the learning goals here. I like the helper methods. Take a look at my comments and let me know if you have questions.

def bfs
raise NotImplementedError
array = []

Choose a reason for hiding this comment

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

Well it's a start!

def initialize
@root = nil
end

# Time Complexity:
# Space Complexity:
# Time Complexity: O(logn) because one side of the tree can be eliminated each time the new key is evaluated against the existing nodes data

Choose a reason for hiding this comment

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

It will be O(log n) if the tree is balanced but O(n) if the tree is totally unbalanced.

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