good lecturer explains things really clearly thanks to Stanford for posting such great videos really good for a review before a test or if you are having trouble with a concept from class.
great video, thanks a bunch. there is one concept i didnt understand. why in binary heap is it necessary for the child to be of greater value than the parent and why bubble the child if it is smaller?
cause that;s how a binary heap works and its not necessary for the parent to be less than its children this representation is done with a min binary heap there is a max binary heap where all children are less. Plus there are like a gazillion other styles of heaps, leftist, fibonacci, etc...
Whoa at 43:40... How can finding the max key take linear time if this is a binary tree? the only way searching a binary tree would take O(N) time is if its degenerate... Shouldn't searching a complete binary tree takes O(log N) time?
Just a minor nitpick: Total order forbids keys to be equal, i.e. both the question answered near the beginning and the insertion of a second "2" would be illegal. OTOH, it might be relevant to be able to do just that (i.e. require only a total preorder), but I don't know whether the algorithms still work with the weakened assumptions.
Well, here is the thing, i've read a couple of articles as well as a book that talk about this issue of priority queue and heap, and i got like an 80% out of the concept but still needed to overcome the weaknesses that i had on this topic. Now, when i watch this video clip i actually got the whole idea of such topic. Great explanations on step by step with clarifying any subtopic by giving great related kind of examples to accomplish the idea of in depth. Thankful for uploading such clip.
Just loved every single us univ. course i've attended at (every one virtually, sadly..) Anyways.. very clean lesson, on such an interesting topic. Thanks for sharing.
mashofsh 7d hena men cmp2013 ><
masrawy2222 1 month ago
thumbs up if he looks like the smart guy from criminal minds
brx360x 2 months ago
جمييل يا وااد ايه الحلاوه دي
مستحمي شكلك
zankalony2014 8 months ago
good lecturer explains things really clearly thanks to Stanford for posting such great videos really good for a review before a test or if you are having trouble with a concept from class.
cpowel2 10 months ago
@cpowel2 UCBerkeley, not Stanford
Killable1337 10 months ago
@cpowel2 Actually UC Berkeley, not Stanford.
hsaziz 9 months ago
very good lecture
Aparna1985Rajeev 11 months ago
Goth teacher except without eye liner :)) hahahahahaha
MaloEdu 1 year ago
UCBerkeley & Jonathan > nptelhrd & Naveen
Just came here from there and they where really boring with all those slides with no writing!
fermixx 1 year ago 2
This course is awesome! Thanks to Mr. Shewchuk and UCBerkeley for this.
ninetaildemon81 1 year ago
great video, thanks a bunch. there is one concept i didnt understand. why in binary heap is it necessary for the child to be of greater value than the parent and why bubble the child if it is smaller?
amalwithoutme 1 year ago
@amalwithoutme
cause that;s how a binary heap works and its not necessary for the parent to be less than its children this representation is done with a min binary heap there is a max binary heap where all children are less. Plus there are like a gazillion other styles of heaps, leftist, fibonacci, etc...
cpowel2 10 months ago
Very shallow coverage of the topic, when compared to the standard of MIT's OCW course 'Introduction to Algorithms' anyway.
blodmangel 1 year ago
watched till 21:00
appamstew 1 year ago
Whoa at 43:40... How can finding the max key take linear time if this is a binary tree? the only way searching a binary tree would take O(N) time is if its degenerate... Shouldn't searching a complete binary tree takes O(log N) time?
TheSemperFudge 1 year ago
@TheSemperFudge you mean a binary search takes O(log n) on a sorted list?
appamstew 1 year ago
@appamstew Yes. If the way the tree is set up is so that the max is first, it would take O(1) time. Else its O(log n) time for anything else.
TheSemperFudge 1 year ago
Comment removed
tomejuan 1 year ago
@TheSemperFudge it takes linear time because you have to traverse the entire tree in order to determine the maximum value.
tomejuan 1 year ago
Very good video. I have a final test tomorrow and this video is better than my teacher. Thank you
benitodel12 1 year ago
Just a minor nitpick: Total order forbids keys to be equal, i.e. both the question answered near the beginning and the insertion of a second "2" would be illegal. OTOH, it might be relevant to be able to do just that (i.e. require only a total preorder), but I don't know whether the algorithms still work with the weakened assumptions.
ralfmuschall 2 years ago
Well, here is the thing, i've read a couple of articles as well as a book that talk about this issue of priority queue and heap, and i got like an 80% out of the concept but still needed to overcome the weaknesses that i had on this topic. Now, when i watch this video clip i actually got the whole idea of such topic. Great explanations on step by step with clarifying any subtopic by giving great related kind of examples to accomplish the idea of in depth. Thankful for uploading such clip.
naa43213 2 years ago 12
he is very smart
branch2washington 2 years ago 4
Very informative. I feel like I finally get it!
Samnsparky 2 years ago 3
Just loved every single us univ. course i've attended at (every one virtually, sadly..) Anyways.. very clean lesson, on such an interesting topic. Thanks for sharing.
blytqb 3 years ago 16
good comment
jyanofski 2 months ago
thanks
jyanofski 2 months ago
@blytqb
jyanofski 2 months ago