Prim's algorithm in 2 minutes

Поділитися
Вставка
  • Опубліковано 3 жов 2024
  • Step by step instructions showing how to run Prim's algorithm on a graph.
    Code: github.com/msa... (different than video, I added this retroactively)
    Source: Algorithms by S. Dasgupta, C. H. Papadimitriou, and U. V. Vazirani [www.amazon.com...]
    LinkedIn: / michael-sambol

КОМЕНТАРІ • 408

  • @himsaragallege4461
    @himsaragallege4461 4 роки тому +1094

    This is the type of channel no-one subscribes to but always expects to come across when searching for a problem.

    • @Jonathan-qz9td
      @Jonathan-qz9td 3 роки тому +20

      haha so true! I have come across this channel so many times lol

    • @sefasenlik
      @sefasenlik 3 роки тому +14

      These channels make their content providers deserve heaven :D

    • @ozparole
      @ozparole 3 роки тому +11

      I subbed, hope this dude makes more stuff.

    • @aviroxi
      @aviroxi 3 роки тому +5

      @@ozparole he stopped doing it 4 years ago.....

    • @ShaizeOn1
      @ShaizeOn1 3 роки тому +14

      this is me searching for path finding algorithms and thinking "why can't i find michael?"

  • @victorcercasin
    @victorcercasin 9 місяців тому +42

    Give this man an award for "straight to the point, no BS"

  • @diogorodrigues9985
    @diogorodrigues9985 Рік тому +90

    2min more usefull than 1 hour college lecture thank you

  • @jakestring6027
    @jakestring6027 Рік тому +115

    This video was absolutely perfect, no idea why my classes have to make this algorithm seem so much more complicated than it has to be, thank you for clearing up a weeks confusion in less than a minute

    • @MichaelSambol
      @MichaelSambol  Рік тому +10

      Thanks, Jake!

    • @Game_Masters
      @Game_Masters Рік тому +5

      My class teacher sucks as well. Some people just can't teach things in simple ways I guess xd

  • @ratedrr_chelsea2074
    @ratedrr_chelsea2074 7 років тому +454

    watching all ur video's the day before my finals!! Ha!

    • @sauvikdas7743
      @sauvikdas7743 5 років тому +36

      30 mins before finals

    • @libinzhou1285
      @libinzhou1285 5 років тому +2

      I'm doing this 10 hours before the final

    • @laravelcommunity2549
      @laravelcommunity2549 5 років тому +16

      And I am watching this in the exam hall 😂😂

    • @reassume4826
      @reassume4826 5 років тому +6

      I am watching after coming out of exam hall.

    • @XxXjellybeans
      @XxXjellybeans 5 років тому +9

      I'm watching this as the teacher is handing out the final

  • @farisdurrani
    @farisdurrani 3 роки тому +107

    Dude, how are you able to explain this so much better than my prof who has written who-knows how many research papers?

    • @MaxRollison
      @MaxRollison 3 роки тому +3

      It's because your professor was going over some other algorithm and forgot to rewatch this video before the lecture. They were probably just a bit rusty on the topic. I mean, it's their bad for not watching this video before lecture again...

    • @eqanio
      @eqanio 3 роки тому +22

      Too much experience with a subject can drag man to include other complexities as well, It's not the professors fault tho, not every professor who has done good research is a good teacher, not everybody has the gift to become a good teacher

    • @MaxRollison
      @MaxRollison 3 роки тому +1

      @@eqanio i agree with this. My algorithms professor is a prime example. Glad I got out of that class alive. Good powerpoints that were ripped from other profs though.

    • @nishantjoshi6712
      @nishantjoshi6712 3 роки тому +5

      because being knowledgeable does not guarantee that someone is good at teaching something.

    • @smilerman
      @smilerman Рік тому +1

      researcher != teacher and my man here proves it

  • @DOMINANTbeats
    @DOMINANTbeats 7 років тому +12

    i want to cry how brief the explanation is! THANK YOUUUUUUUUUU

  • @firefist8619
    @firefist8619 8 років тому +79

    finally an easy one!!! not like those hard ,not getting any idea posts
    thnx

  • @anoniem012
    @anoniem012 4 роки тому +26

    When you think CS is too difficult for you (getting depressed about having no future, and all-time spent for nothing) and see afterward that it is actually easy but that you are more efficient in learning by this structure of lecturing.

    • @THarshavardhanReddy
      @THarshavardhanReddy 2 роки тому +2

      It's OK. Everybody feels this. If we get through to the other side, you'll have that awesome feeling of overcoming a challenge. And that feels really wonderful :)

    • @anoniem012
      @anoniem012 2 роки тому +1

      @@THarshavardhanReddy Allahu ekber!

  • @shatterspace2444
    @shatterspace2444 Рік тому +5

    This was perfectly explained! Needed to create a Minimum Spanning Tree for a Dungeon Generation Algorithm and didn't know where to start. This really helped me out!

  • @dimitrioskarageorgos5996
    @dimitrioskarageorgos5996 4 роки тому +5

    You just did in 2 minutes what most proffessors can't in 2 hours. Nice job

  • @codingit9504
    @codingit9504 Рік тому +1

    This is just Insane! Sir !! please make more such videos! This is just gold pure gold!! I am delighted to have encounter this channel TBH!!

  • @TanmoyTheDeadBoy
    @TanmoyTheDeadBoy 9 років тому +38

    After 2 semester I totally forgot what it is. Now I needed it again for this semester but missed the class. :P
    Thanks for the rescue :P

  • @thomasdignan6884
    @thomasdignan6884 4 роки тому +1

    When you really understand something, you can explain it simply, and this video is a great example.

  • @aslmate
    @aslmate 24 дні тому

    You explain way better than my university professor and only in 2 minutes! That's insane!

  • @Cyber99221
    @Cyber99221 3 роки тому +1

    I love the fact everything is done under 2 minutes. Love the videos

  • @yashjkl7055
    @yashjkl7055 2 роки тому +3

    I love this kind of videos straight to the point.

  • @RawanMk
    @RawanMk 9 років тому +68

    Best example so far, I FINALLY understand it!

    • @atulrawat9588
      @atulrawat9588 5 років тому

      Hi rawan

    • @IStMl
      @IStMl 4 роки тому +1

      @@atulrawat9588 lmao

    • @IStMl
      @IStMl 4 роки тому

      @@atulrawat9588 lmao

    • @360Gunsnroses
      @360Gunsnroses 4 роки тому

      @@atulrawat9588 game on!!!

    • @school_pizza
      @school_pizza 4 роки тому +1

      @@atulrawat9588 desperate much? lol

  • @adelalmohtaseb5261
    @adelalmohtaseb5261 Рік тому +1

    Thank you so much, i couldn't understand a world for my exam now i finally get it.

  • @kartavyasingh5894
    @kartavyasingh5894 Рік тому +1

    thanks to michael, i studied for my university test in just 2 hours

  • @supernerd10000000000
    @supernerd10000000000 7 років тому +8

    Hey thanks for your help! Your videos are the best out there. So easy to understand by seeing an actual step by step example with no fluff.

  • @fadsmfawopefaw
    @fadsmfawopefaw Рік тому +4

    Thanks for making such concise, easily-digestible videos. You're a great teacher and we all appreciate the thought that goes into these to get them to this quality!

  • @alexeukleidis1611
    @alexeukleidis1611 9 років тому +3

    Sir you are the Best!!!!!!!
    The shortest and meaningful video that can be created!!!!
    Thank you SO much!!!!

  • @tysontakayushi8394
    @tysontakayushi8394 Рік тому +1

    Beautiful! And the fact that you wrote a new graph on your paper for each change, chapeau!

  • @akshaynarasimhan2
    @akshaynarasimhan2 Рік тому +1

    Love this channel! subscribed! Keep churning out more and more content man!

  • @benjaminmcintosh857
    @benjaminmcintosh857 5 років тому +1

    Love reading the comments on all your vids and seeing half of them being people right about to sit an exam

  • @sarthaksharma5860
    @sarthaksharma5860 Рік тому +1

    1hour topic covered in 2min 💀 you are genius

  • @drewkelly3622
    @drewkelly3622 9 місяців тому +1

    my professor drew graphs and showed us multiple slides that made no sense when you explained 100x better in 2 minutes.

  • @Scimitars-in-sandstone
    @Scimitars-in-sandstone Рік тому +1

    The was such a life-saver! I’m in a higher math/computer science class with a teacher I can barely understand. 😅 This helped a ton thank you so much!

  • @jackganly4993
    @jackganly4993 5 років тому +6

    This video helped a ton with my coding test, saved me a few %. Thanks man, really well made.

  • @javiergonzalez5842
    @javiergonzalez5842 6 місяців тому +1

    Insanely simple explanation, great

  • @joshelguapo5563
    @joshelguapo5563 3 роки тому

    Watching quality material like this on youtube is a constant reminder of how shitty my education is ending up being.

  • @krrangarajan5391
    @krrangarajan5391 2 місяці тому +1

    Thanks for this, Better than a 2 uni lecture!!

  • @leddfarmer
    @leddfarmer 6 років тому

    Oh my gosh, I thought I was just stupid because I could not understand this in class. Now I realize my professor just made it 10x more confusing. Thank you!!

  • @MrMrTierry
    @MrMrTierry 8 років тому +5

    Those videos are just great! Straight to the point and exactly what you need to understand. Thanks a lot!

  • @CarterRMadsen
    @CarterRMadsen 4 роки тому +2

    Michael, this is manna from heaven to us college students during finals week:D You've done us a huge service!

  • @isura.m
    @isura.m 8 років тому +5

    Thanks man. I didn't go to lectures because I am lazy. You saved me :D

  • @sask1a41
    @sask1a41 4 роки тому +1

    Youre amazing you know. 15hours of lectures compressed into 2mins

  • @summerschool6194
    @summerschool6194 5 років тому

    how are you so smart to teach in such an efficient way

  • @mrntube1
    @mrntube1 10 років тому +1

    Simple yet effective explanation.

  • @eylulranasarac
    @eylulranasarac Рік тому

    This video is an art. Simplest explanation ever.

  • @kartiksharma5428
    @kartiksharma5428 9 місяців тому

    Why you stopped uploading these videos...this was the first question came into my mind after finding this gold channel. Loved your hardwork❤

  • @racram0444
    @racram0444 Рік тому

    Because of you I've aced my data structures exam, I am extremely grateful

  • @bogslut
    @bogslut 5 років тому

    This channel is a lifesaver. The explanation is much easier to understand unlike our professor's rambling.

  • @wegamers868
    @wegamers868 2 місяці тому

    thanku bro ,this helped me out today after 11 years. handsoff

  • @adnanemezrag3809
    @adnanemezrag3809 4 місяці тому

    Very straight forwarrd explanation. Well done mate.

  • @user-wi6pc1on9d
    @user-wi6pc1on9d Рік тому +2

    Great explanation and simple! Thank you Michael!

  • @karmeljt7011
    @karmeljt7011 3 роки тому

    the fastest and greatest tutorial i have ever seen

  • @sunpope8002
    @sunpope8002 6 років тому

    short sweet and to the point. good refresher or intro for anyone learning computer science/ discrete mathematics

  • @CatalunaLilith
    @CatalunaLilith 3 роки тому

    and everyone else takes 15+ minutes to give a worst explanation. you're great

  • @Peter_Andrews
    @Peter_Andrews Рік тому +1

    He explains perfectly. Thank you

  • @peeper2070
    @peeper2070 3 роки тому +5

    It’s not an educational video if there aren’t ‘you taught me better than my professor’ comments

  • @Kuzame
    @Kuzame 8 років тому +1

    Had an assignment due in 10 mins earlier, saw this 2 mins--perfect! Glad it's a crystal clear explanation & visualization

  • @Meatamir
    @Meatamir 6 років тому

    It so nice when a video is great and to the point.

  • @berryberrybear2395
    @berryberrybear2395 Рік тому +1

    Wonderful explanation in 2 minutes

  • @Zeppelin-ep7uv
    @Zeppelin-ep7uv 3 роки тому +3

    I have never had a Prim tutorial as good as this, thank you! 😁

  • @alexkim8965
    @alexkim8965 5 років тому +1

    Your example is better than my professor's example where next node to visit always happen to be the one adjacent to the one that just got visited, which confused me...

  • @dianacarely19
    @dianacarely19 10 років тому +5

    Great videos! Simple, to the point, and fast. I hate 7 minute videos where they take their time, by that point I have lost interest. Good JOB! Keep up the great work!

  • @grab2win982
    @grab2win982 6 років тому

    Takes Profs an hour to explain this stuff. Thank you for saving my time

  • @rizreighnand6471
    @rizreighnand6471 6 років тому

    omg your short videos are very helpful for me to pass my semester
    thank you so much

  • @LLLLLLEON216
    @LLLLLLEON216 8 років тому +7

    Best explanation I've seen so far!

  • @yoty66
    @yoty66 6 років тому +3

    Review in 1 word: perfect!

  • @gabrielabdm2839
    @gabrielabdm2839 5 років тому

    had to leave a comment to thank you, cause this video is the best i've seen so far, congrats!

  • @kagame6524
    @kagame6524 10 років тому +13

    As useful as it is brief. Thanks a lot!

  • @tranminhquang4541
    @tranminhquang4541 2 місяці тому

    Thanks so much for this ! Such a concise way to explain the problem!

  • @nib0lase926
    @nib0lase926 4 роки тому +6

    He had to draw that tree like 20 times haha. Great explanation!!!

  • @roshithradhakrishnan2931
    @roshithradhakrishnan2931 8 років тому +1

    Awesome. After watching this 4 the first time, I came to know what is prim"s algorithm.

    • @MichaelSambol
      @MichaelSambol  8 років тому +1

      Glad you enjoyed. Thanks for watching. :)

  • @chaz-e
    @chaz-e 10 років тому

    Short and tidy, indeed deserves a thumbs up!

  • @sporkineye
    @sporkineye 5 років тому +39

    how did my teacher make this so hard

  • @jetswhiteout961
    @jetswhiteout961 6 років тому

    This helped a ton. Simple explanation, 2 minutes, awesome.

  • @josearias708
    @josearias708 7 років тому +1

    Dude , you're a life saver.
    Thanks a lot

  • @mrincodi
    @mrincodi 6 років тому

    This was super-clear and short! Thanks!

  • @anotherplayer1546
    @anotherplayer1546 5 років тому

    Teaching is a talent, and you got it. Thanks, man.

  • @probinertasks6087
    @probinertasks6087 2 роки тому

    This was super clear presentation and quick... Very well done.

  • @yogeshmandge4730
    @yogeshmandge4730 8 років тому +2

    Hey +Michael Sambol great work mate!
    And I have a small request, please make videos for Greedy strategy, Dynamic programming and also Divide and Conquer strategy.

  • @ToTaLShaFF
    @ToTaLShaFF Рік тому

    Two minutes, absolutely amazing!

  • @JamesBrodski
    @JamesBrodski Рік тому +1

    What a great video! God bless you for making it.

  • @saurabhsomani582
    @saurabhsomani582 6 років тому

    Genius content! If only other youtubers could teach in short time...

  • @solopine9624
    @solopine9624 5 років тому

    Thanks bro, great review. Covered half my lecture slides in 2 min.

  • @xMrVideo
    @xMrVideo 11 місяців тому

    My man, 50% of my CS degree is thanks to your vids. Thank you

    • @MichaelSambol
      @MichaelSambol  11 місяців тому +3

      Boom! I think 5% of your first signing bonus to me is fair. 🤪😎

  • @JAlternative106
    @JAlternative106 8 років тому

    Hey Micheal, you have great videos man! Thank you for doing these.

  • @peeyushsrj
    @peeyushsrj 8 років тому +11

    Thanks a lot, very useful in exam time :D

  • @reannabromley4648
    @reannabromley4648 6 років тому

    Exceptionally clear and concise. Thank you.

  • @bill-wg7ph
    @bill-wg7ph 5 місяців тому

    why can't all instruction videos be like this!? This took my professor ~4 hours to explain

  • @markfantone1253
    @markfantone1253 9 років тому

    Cool, I can't understand this lesson taught by our professor. But with this Review I've finally understand what's going on in Prim's Algorithm. (y)

  • @faheemjan2840
    @faheemjan2840 11 років тому

    wow...in two minutes ...thank you very very very very much...this is really very helpful..thank you

  • @bengper8044
    @bengper8044 5 років тому

    Those quick videos are very helpful, thanks

  • @firebraingames
    @firebraingames 3 роки тому

    Worth 1 week of computer science class

  • @nazkord
    @nazkord 5 років тому

    The clearest explanation ever!

  • @shorty235z
    @shorty235z 7 років тому

    Genius! Someone give this man a Nobel Prize!

  • @mickeymouser626
    @mickeymouser626 8 років тому +1

    Thank you so much! Tomorrow's my exam... learned a lot btw :)

  • @RealTyrax
    @RealTyrax 8 років тому

    Thanks a lot man. I missed the explanation for this in college and it helped me a lot.

  • @ikej1200
    @ikej1200 5 років тому

    Best video ive seen on this subject thanks so much!

  • @ahmadrezagha2787
    @ahmadrezagha2787 8 років тому +1

    Hello buddy, Thank you very much. I Have Learnt So much about the algorithms.

  • @MichjuX
    @MichjuX 10 місяців тому

    You explained it in 2 minutes better than my teacher in 15 minutes XD

  • @shankarn4021
    @shankarn4021 9 років тому

    Awesome . Short and the best source

  • @leooel4650
    @leooel4650 4 роки тому

    2 minutes covered 2 hours!
    Cheers Michael!

  • @sawvikdipto3087
    @sawvikdipto3087 Рік тому

    this is just awesome, saves time, makes clear. totally Greedy approach.
    Thanks a lot

  • @varshinibandaru6109
    @varshinibandaru6109 10 років тому +2

    its very clear and brief..thank u so much :)

  • @callmejobson
    @callmejobson 10 років тому

    a lot better than my teacher thanks for the help