Skip to content

Conversation

@stpatrickschild
Copy link

Heaps Practice

Congratulations! You're submitting your assignment!

Comprehension Questions

Question Answer
How is a Heap different from a Binary Search Tree? every time a heap is a complete tree, and each parent has a specific order relationship with their children.
Could you build a heap with linked nodes? yes. but there are easier ways.
Why is adding a node to a heap an O(log n) operation? because it need to make a comparison at each tree level.
Were the heap_up & heap_down methods useful? Why? yes there were, to compare the parent/child.

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.

1 participant