Lecture 1: Algorithmic Thinking, Peak Finding

แชร์
ฝัง
  • เผยแพร่เมื่อ 4 ก.พ. 2025

ความคิดเห็น • 2.1K

  • @bkboggy
    @bkboggy 8 ปีที่แล้ว +6650

    It's so cool that these top schools release courses like this one online free of charge. I may not get a chance to go to MIT or Stanford, but I'm sure as heck going to learn as much as I can from them. Thanks!

    • @ATXpert
      @ATXpert 7 ปีที่แล้ว +12

      sellout

    • @SpaghettiToaster
      @SpaghettiToaster 7 ปีที่แล้ว +113

      MIT gets billions of government funding. Billions.

    • @QQTrick1QQ
      @QQTrick1QQ 6 ปีที่แล้ว +27

      I paid for my MIT education in cash!

    • @vertigo6982
      @vertigo6982 6 ปีที่แล้ว +52

      Its like real life.. you can go in most big university classes, sit down and learn for free... (as long as there's an open seat)

    • @danielj9865
      @danielj9865 6 ปีที่แล้ว +4

      ATXpert sellout because hes sharing knowledge?

  • @vertigo6982
    @vertigo6982 6 ปีที่แล้ว +2633

    MIT Tuition is $49,892/yr $24,946 /per semester which is about $4,989.20 per course. Semester runs 15 weeks. So that equals to about $332.61 per week.. I'd say this course runs twice a week, so this day of class cost $166.30, and you got it for free. Now that's what it cost.. what it's worth is much more.
    Moral of the story. Be thankful to have such information at our fingertips. FREE MIT courses on Algorithms?!? How awesome is that!?

    • @blasttrash
      @blasttrash 5 ปีที่แล้ว +188

      True, but just to point out, that $166 also includes the ability to talk with peers, professors, teaching assistants etc. It might also include the usage a cluster or supercomputer that MIT runs.
      And such free education is only good for some courses like Computer Science or theory knowledge in most of the other disciplines. For example, if you are learning electronics, you can get free theory knowledge from such videos, but you wont get any practical knowledge about soldering or circuit design etc coz you would need real hardware. Same applies with biology etc.
      However, we should indeed be grateful for such videos.

    • @dingoDogMan
      @dingoDogMan 5 ปีที่แล้ว +78

      @@blasttrash It's worth noting that students are also paying this money for a qualification and proof for potential employers that they possess all of this knowledge.

    • @slackerengi2401
      @slackerengi2401 5 ปีที่แล้ว +31

      Goodwill hunting
      A library card goes a long way

    • @slackerengi2401
      @slackerengi2401 5 ปีที่แล้ว +27

      @@blasttrash
      EE student here,
      bought components, soldering iron, and multimeter on Amazon
      Saw free lectures on TH-cam and instructables
      Knowing what the knobs on a osciliscope do before touching it is great, most in my class had no clue(Myself included)
      But ultimatly expirience of any kind is king, especially self taught
      You may not have a supercomputer, but you defenitly got the knoledge and will to learn
      Some in those classes don't even have that

    • @blasttrash
      @blasttrash 5 ปีที่แล้ว +11

      @@slackerengi2401 True its all about will. I am from ECE too, although I graduated long back and I dont even know how to solder stuff. I can barely remember the difference between series and parallel connections on a bread board.
      I work in CS field now, so all is good I guess. :)

  • @emo_nemo
    @emo_nemo 8 ปีที่แล้ว +3534

    The lecture starts at 0:22.
    Course overview : 2:51
    Course content : 8:37
    First problem (Peak finder) : 15:31
    "Straight forward" algorithm : 18:53
    "Divide & Conquer" (a recursive) algorithm : 27:42
    Second problem (2D Peak finder) : 36:16
    Greedy Ascent algorithm : 37:30
    "Divide & Conquer 2D" algorithm (defunct) : 42:40
    "A working 2D recursive" algorithm : 47:35

    • @akshaybhatt8332
      @akshaybhatt8332 8 ปีที่แล้ว +11

      bro could plz suggest me the best data structure video channel...i'm a begineer

    • @grahamcracker-inc
      @grahamcracker-inc 8 ปีที่แล้ว +7

      You're awesome

    • @Lens_lores
      @Lens_lores 8 ปีที่แล้ว +33

      doing god's work

    • @BULLSHXTYT
      @BULLSHXTYT 7 ปีที่แล้ว +11

      Wow I love you bro.

    • @player1coding958
      @player1coding958 7 ปีที่แล้ว +16

      Where's my fucking son?

  • @elizabethphillips1496
    @elizabethphillips1496 4 ปีที่แล้ว +308

    I failed math in high school and over 20 years later actually enjoyed watching and learning from this. I’ve been interested in algorithms and appreciate MIT sharing this class session.

    • @PHlophe
      @PHlophe 4 ปีที่แล้ว +28

      girl you are not alone. but i am thinking its because its now that you can understand what you can do with mathematics. in our days we were taught math and physics like robots. We had to shove everything inside that head or get whippings.

    • @mastershooter64
      @mastershooter64 4 ปีที่แล้ว +15

      @@PHlophe ngl it's still taught like that

    • @deanmason7160
      @deanmason7160 4 ปีที่แล้ว

      @@mastershooter64 this is a straightforward Algorithm

    • @jeffschlarb4965
      @jeffschlarb4965 4 ปีที่แล้ว +4

      endless supply ...Stanford, Berkeley, CMU, Cal Tech and Harvard ...machine learning, AI....

    • @notagain3732
      @notagain3732 2 ปีที่แล้ว +2

      Math is something one can learn at any age , yes it can be difficult but with propper material this challenge we call education can become simple when all the steps are clear and at any given time the next step is obvious . Join a community online , that is much better than self learning by its self

  • @mauricemaeterlinck8799
    @mauricemaeterlinck8799 4 ปีที่แล้ว +146

    It feels like this Professor is very passionate and knowledgeable about the course material! The hour flew by

    • @obicaban1269
      @obicaban1269 4 ปีที่แล้ว +8

      set playback at higher than 1x... flies by even faster ;P

    • @jeffschlarb4965
      @jeffschlarb4965 4 ปีที่แล้ว +1

      Try Harvard CS 50

    • @harv609
      @harv609 3 ปีที่แล้ว +1

      @@jeffschlarb4965 that's a foundational course, this one's lil more advanced than that

    • @jeffschlarb4965
      @jeffschlarb4965 3 ปีที่แล้ว +1

      @@harv609 I was speaking in regards to a passionate teaching style...

    • @harv609
      @harv609 3 ปีที่แล้ว +1

      @@jeffschlarb4965 oh I see, yeah. I agree

  • @KrutikaPatil0109
    @KrutikaPatil0109 3 ปีที่แล้ว +251

    Really grateful to MIT and Srini for making this course accessible through OCW... Really enjoyed this course

    • @akainu3668
      @akainu3668 3 ปีที่แล้ว

      Alongside this course what did you follow to master ds, algo?

    • @KrutikaPatil0109
      @KrutikaPatil0109 3 ปีที่แล้ว +2

      CLRS

    • @bat_man1138
      @bat_man1138 3 ปีที่แล้ว

      Was it worth??i mean whole course

    • @juanmoscoso0
      @juanmoscoso0 3 ปีที่แล้ว

      @@KrutikaPatil0109 you read all of it?

    • @ramansarabha871
      @ramansarabha871 3 ปีที่แล้ว

      @@juanmoscoso0 I doubt that. She did Andrew Ng's deeplearning specialization, was familiar was supervised, unsupervised and semi-supervised learning from work.

  • @giwrgosnikolaidis1096
    @giwrgosnikolaidis1096 2 ปีที่แล้ว +31

    I actually passed the equivalent course to my university by watching these videos. I also scored an almost perfect score! These videos are a goldmine! Thanks a lot for providing these courses to the general public.

    • @annapatata6258
      @annapatata6258 2 ปีที่แล้ว

      se poio panepisthmeio

    • @giwrgosnikolaidis1096
      @giwrgosnikolaidis1096 2 ปีที่แล้ว +1

      @@annapatata6258 Μετσόβιο

    • @annapatata6258
      @annapatata6258 2 ปีที่แล้ว

      @@giwrgosnikolaidis1096 etsii kai egw ekei eimai

    • @giwrgosnikolaidis1096
      @giwrgosnikolaidis1096 2 ปีที่แล้ว +1

      @@annapatata6258 odws? Ara h hmmy h semfe eisai. Opws kai na exei bohthane full. Egw me auta ta video perasa algorithmous.

    • @annapatata6258
      @annapatata6258 2 ปีที่แล้ว

      @@giwrgosnikolaidis1096 hmmy eimai 1o etos

  • @shubhamrauniyar101
    @shubhamrauniyar101 4 ปีที่แล้ว +39

    Thanks MIT for the course. I can now understand things very easily as a correspondence student, it's very hard to understand things, but MIT open course-ware has made life and learning very easy.

  • @4cricket24
    @4cricket24 5 ปีที่แล้ว +116

    Great initiative by MIT. I never imagined i will be able to sit and learn from an MIT professor for free!! 👍
    എല്ലാ മലയാളികൾക്കും എന്റെ ഹായ്

  • @thepianist7379
    @thepianist7379 11 หลายเดือนก่อน +13

    No bullshit, no cheap jokes. Just pure joy of knowledge. How college courses should be taught!

  • @anusha5788
    @anusha5788 2 หลายเดือนก่อน +4

    MIT Courses Order to master Algorithms:
    6.001 Intro to CS and Programming in Python: th-cam.com/video/nykOeWgQcHM/w-d-xo.html
    6.S095 IAP 2018 Programing for the Puzzled: th-cam.com/video/14UlXIZzwE4/w-d-xo.html
    6.042J Mathematics of Computer Science: th-cam.com/video/L3LMbpZIKhQ/w-d-xo.html
    6.006 Introduction to Algorithms: th-cam.com/video/HtSuA80QTyo/w-d-xo.html
    6.046 Design and Analysis of Algorithms: th-cam.com/video/2P-yW7LQr08/w-d-xo.html

  • @fgfanta
    @fgfanta 6 ปีที่แล้ว +75

    This is still the best on-line introductory course for algorithms I am aware of. Coupled with programming exercises, it would make legendary content for MITx and edX.

  • @arindam1249
    @arindam1249 3 ปีที่แล้ว +11

    Honestly, the best lesson I've ever watched!
    MIT is the best for a reason! I'd never hesitate to dive right into MIT OCW by this time.

  • @TrendingPoonai
    @TrendingPoonai 5 ปีที่แล้ว +67

    Learning a course after a lecture feels like I'm into college, Thank you so much MIT for all your open source curriculum 😊🙏🙏🙏

  • @kritgrover
    @kritgrover 3 ปีที่แล้ว +31

    Just finished 6.0001 and 6.042J, now starting 6.006, just as a head start before I join university next year. Really grateful to MIT to provide these lectures for free.

    • @giannizamora7247
      @giannizamora7247 3 ปีที่แล้ว +14

      you will have a great understanding already going into uni. Good luck on your studies. I wish I had dived into these courses when I started my programming journey.

    • @aishwaryadharmadhikari7165
      @aishwaryadharmadhikari7165 3 ปีที่แล้ว +7

      I'll do those 2 first you did, they seem pretty good. Thanks for commenting man !

    • @kritgrover
      @kritgrover 3 ปีที่แล้ว +1

      @@aishwaryadharmadhikari7165 yup they are very helpful and infact they are the prerequisites for this course.

    • @dejidevi3990
      @dejidevi3990 2 ปีที่แล้ว +1

      @krit grover could you please share the link of 6.0001 and6.042J,and 6.006 ,pizzazz
      It would be a great help for others, plzzz share

    • @dejidevi3990
      @dejidevi3990 2 ปีที่แล้ว

      @Aishwariya dharmadhikari plzzz provide all the link

  • @samyakjain7300
    @samyakjain7300 3 ปีที่แล้ว +345

    "Inefficient but correct is definitely better than being efficient but incorrect" - Srini Devdas

    • @marcospark2803
      @marcospark2803 2 ปีที่แล้ว +25

      Pretty obvious.

    • @Daniel_WR_Hart
      @Daniel_WR_Hart 2 ปีที่แล้ว +7

      "Move fast and break things." - The Zuck

    • @Pedro-zh6kk
      @Pedro-zh6kk ปีที่แล้ว +1

      the mantra of cryptograph and information security in general

    • @realE.C
      @realE.C ปีที่แล้ว +3

      "but it works" -literally every programmer

    • @wyqtor
      @wyqtor หลายเดือนก่อน

      In a select few cases, it's better to be slightly incorrect but efficient (mp3, jpeg are a few examples of useful lossy compression). Hell, even LLM weights - ChatGPT might hallucinate from time to time, but it would be impractical to build without some lossy compression involved.

  • @AshutoshShelkeP
    @AshutoshShelkeP 2 ปีที่แล้ว +20

    I cried. Just visit the link in description and see how wonderfully everything is arranged for us to learn. Thank you team MIT. I cannot explain what this means to a student like me from small indian village. It's a dream come true. Best gift for life.

    • @anarghanayak8586
      @anarghanayak8586 2 ปีที่แล้ว +3

      hey bro i have just learned all the basic and important things on java..can you suggest me from where i can study and concepts of dsa..plz help me i am about to sit on my college placements

    • @ANDROHACKS
      @ANDROHACKS 2 ปีที่แล้ว

      @@anarghanayak8586 th-cam.com/play/PLUl4u3cNGP6317WaSNfmCvGym2ucw3oGp.html

    • @jasminetea4574
      @jasminetea4574 2 ปีที่แล้ว

      xd

  • @premgarg5534
    @premgarg5534 3 ปีที่แล้ว +34

    Don't worry about peak finding algo. If u r confused about binary vs random for 1d peak finding or global peak vs relative one, just learn that this video is for introduction and give students with non programming background a feel of algorithms and a little of divide & conquer. Hope u watch the whole playlist and i can assure you there are no such confusions in later videos!
    Thanks MIT for the amazing playlist

    • @das6109
      @das6109 ปีที่แล้ว +3

      I feel really dumb about this problem.
      I don't understand how it's log(n). I figure you need to check around you on both sides to know if you're a peak. But also you can't eliminate more elements than the ones directly around you as potential peaks because the array is unsorted. How are we cutting potential solutions in half on every check? I've understood some DSA concepts, but even this first class just left me confused lol.
      Edit: Ah I misunderstood the problem. We're looking for any peak not the highest number. We know that if a number is higher we can jump into the middle of that side of the array and if the number to our left is higher than there must be a peak between the one we started with and the one we just chose. If the number on the right is higher instead we just keep cutting through. Worst case scenario the numbers just increase constantly in one direction and we eventually find the only peak on the extreme right of or left of the array.

    • @oneowone6928
      @oneowone6928 ปีที่แล้ว +1

      @@das6109 That was exactly my concern lol, from first go it looks like we may skip a peak on the side we're skipping, but seems like if A >= B, then there is a guaranteed peak on side which includes A :)

    • @fwang3695
      @fwang3695 21 วันที่ผ่านมา

      @@das6109 thanks for the clarification. it makes more sense to me now.

  • @bikeshregmi946
    @bikeshregmi946 3 ปีที่แล้ว +18

    I really feel like I am at MIT and having a live Lecture. Thank You, MIT

  • @RushabhShahclwarrior
    @RushabhShahclwarrior 3 ปีที่แล้ว +4

    I just wish i had find this earlier in my career, but back then I was not ready to understand how blessed I am to access this. MIT is dream but I can access such courses at my fingertips now!!

  • @JohnnyDoeDoeDoe
    @JohnnyDoeDoeDoe 11 ปีที่แล้ว +293

    I felt smarter after watching just the course overview, excited to watch the entire series!

    • @aashish77
      @aashish77 4 ปีที่แล้ว +1

      Hey

    • @hosea_br
      @hosea_br 3 ปีที่แล้ว +5

      @Deonex replying to a 7 y/o comment xdd

    • @danid1464
      @danid1464 3 ปีที่แล้ว +4

      Hello, how are you after 7 years?

    • @JohnnyDoeDoeDoe
      @JohnnyDoeDoeDoe 3 ปีที่แล้ว +30

      @@danid1464 I'm a full on software engineer! Did an internship at Microsoft and have been working at startups which interest me since then

    • @user-zv7yb4yp9g
      @user-zv7yb4yp9g 3 ปีที่แล้ว +4

      @@JohnnyDoeDoeDoe man, this gives me hope for the future. I'm wondering, did you go to a university?

  • @janmichaelaustria620
    @janmichaelaustria620 3 ปีที่แล้ว +36

    I remember taking an intro to Algos class as an undergraduate way back when. And I remember not having the slightest idea how to get O(logN) for the peak finding problem. And then just being in total shock when some student from the back answered it the first day, like at @24:52, thinking that kid was the next Dijkstra or Primm lol. I'm now in my 30's grinding away at leetcode and reading CLRS for interviews. And now that I think about it, that kid at @24:52, was already doing what I'm doing now well before he even took the class. Start while you're really young!

    • @utkarsh_108
      @utkarsh_108 3 ปีที่แล้ว

      do you think in long term software engineer role is good considering the dynamic nature of job scenario

    • @Wereld03
      @Wereld03 3 ปีที่แล้ว

      @@utkarsh_108 software engineering as in dumb code, probably not. But there will always be a need for people that can solve problems and put that into code as a tool or final product

    • @ViktorKishankov
      @ViktorKishankov 2 ปีที่แล้ว +2

      The array there is not necessary sorted, so binary search doesn’t seem like a valid approach. Did I miss something?

    • @Everspy
      @Everspy 2 ปีที่แล้ว +1

      ​@@ViktorKishankov All you need to do is find ANY peak in the array. The search starts in the middle, if the value is rising to the left, there must a peak somewhere on the left, same for the right. Otherwise, you must already be on a peak. Imagine you were on a mountain looking for a peak, you would head in the direction where you have to walk uphill. Binary search works because it is any peak, not the greatest peak.

  • @jaisuriyar5259
    @jaisuriyar5259 5 ปีที่แล้ว +44

    Keep it up MIT ....it's such a nice job to give lectures from excellent professors in online for completely free.....THANKS

  • @Shafmohaa
    @Shafmohaa 4 ปีที่แล้ว +1

    Complete course: 47 Videos
    th-cam.com/play/PLUl4u3cNGP61Oq3tWYp6V_F-5jb5L2iHb.html

  • @NORTE_559
    @NORTE_559 4 ปีที่แล้ว +104

    I have absolutely no clue what he's talking about but yet I'm here listening like I'm really trying to learn it .

    • @abraiyan7984
      @abraiyan7984 4 ปีที่แล้ว +17

      Spend some time on a Basic Data Structure course. It will make sense then.

    • @Thisisnotmyrealname8
      @Thisisnotmyrealname8 3 ปีที่แล้ว +2

      @@yojodingy6334 Can you please explain what an algorithm is?

    • @abhishekpanthi6496
      @abhishekpanthi6496 3 ปีที่แล้ว +3

      @@yojodingy6334 hey!! stop acting Smart and try to get a life please!!

  • @wontpower
    @wontpower 5 ปีที่แล้ว +30

    I seriously envy the professors at MIT. The profs at my university can't hold a candle to their organization and ability to simplify difficult concepts.

    • @synthesizedsimurgh2127
      @synthesizedsimurgh2127 2 ปีที่แล้ว +5

      My uni professors make simple concepts more difficult, what's worse is that they do it with confidence.

  • @pranki2254
    @pranki2254 3 ปีที่แล้ว +8

    this is wonderful. Not having to depend on incomplete resources across the internet and then coming across the complete course taught by the BEST is wonderful. Please do put more such courses and help those students who can't afford to have a quality education for one or the other reason, thank you

  • @aidenrichard2898
    @aidenrichard2898 3 ปีที่แล้ว +1006

    What if the cameraman started learning from this lecture and finds himself becoming a programmer :)

    • @rintrah81
      @rintrah81 3 ปีที่แล้ว +129

      He’s already programmed a robot to do the camera work.

    • @mirtuzzamitthi4755
      @mirtuzzamitthi4755 3 ปีที่แล้ว +28

      MIT president is the cameraman.

    • @rachakondaeshwar4129
      @rachakondaeshwar4129 3 ปีที่แล้ว +3

      Yep

    • @patrickalegria7620
      @patrickalegria7620 3 ปีที่แล้ว +4

      Or the janitor.

    • @dwightpeters
      @dwightpeters 3 ปีที่แล้ว +44

      Nothing wrong with being a cameraman. If you imagine a world with only programmers, it would be awful

  • @anupamdubey5736
    @anupamdubey5736 3 ปีที่แล้ว

    One of those best initiatives I have ever come across. It would create monopoly in the Indian market over all ed-tech platforms and offline coaching tuitions. Only a matter of awareness. Never heard a negative review about this.

  • @syd6358
    @syd6358 ปีที่แล้ว +1

    15:30 specific problem -peak finder
    28:10 divide conquer algorithm
    34:30 how usefulness depends on size of input data
    36:15 peak for 2d

  • @DentrifixoRam88
    @DentrifixoRam88 7 ปีที่แล้ว +10

    Watching this video from Argentina and I think it's amazing and great you guys share this w/ the community. Thanks!!

  • @encrypt3dbr0k3r
    @encrypt3dbr0k3r 3 ปีที่แล้ว +5

    Thank you MIT for uploading this content. Its truly a blessing and you are doing a good service to our planet Earth.

  • @mmkvhornet7522
    @mmkvhornet7522 2 ปีที่แล้ว +9

    Wow what a course !! the professor makes it so easy to understand algorithms thank you MIT !

  • @aghileslounis
    @aghileslounis 2 ปีที่แล้ว +1

    What a time to be alive for having such high quality course for free, free education is the best thing that can happen to humans, learn from each other for free, i understand it's difficult to have free education or anything really, because those people need to be payed to live also, but if we can find a way to have as much free education as possible it's just incredible and highly valuable for humanity, and MIT are doing a great job by contributing to this project/idea, thank you

  • @actualprogramming
    @actualprogramming 4 ปีที่แล้ว +1

    best time to be alive, you can study from best teacher across the world for free at home.

  • @rkirmizi
    @rkirmizi 8 ปีที่แล้ว +47

    This channel is a gold mine. I'm so happy about finding this :D Thank you very much.

    • @sharadrajput379
      @sharadrajput379 4 ปีที่แล้ว

      This channel is a goldmine. Great information

  • @PeterReginald
    @PeterReginald 8 ปีที่แล้ว +406

    Prerequisites
    A firm grasp of Python and a solid background in discrete mathematics are necessary prerequisites to this course. You are expected to have mastered the material presented in 6.01 Introduction to EECS I and 6.042J Mathematics for Computer Science.
    If you have not taken and been successful in each of these subjects, please speak with a TA or professor before enrolling. We do allow students who have equivalent, other experience with the material described above to enroll, but with the firm understanding that mastery of this material is assumed and that course staff will not feel obligated to cover it or to help students who are struggling with it.
    6.006 is a 12-unit (4-0-8) subject and serves as a Foundational Computer Science subject under the new curriculum. It is a direct prerequisite for 6.046 Design and Analysis of Algorithms, the theory header.

    • @BoredChinese
      @BoredChinese 8 ปีที่แล้ว +11

      Wait so I won't learn anything if I only know C?

    • @PeterReginald
      @PeterReginald 8 ปีที่แล้ว +13

      Bored Chinese Even though this class uses Python you could still learn something. Really depends on your ability to grasp and apply the lessons to the C language.

    • @sandeeprmohanty123
      @sandeeprmohanty123 8 ปีที่แล้ว +2

      Hi Could you please provide the link or direct to proper links for the prerequisite courses. I searched in ocw.mit site but there are 4 courses(Spring 2005/2010 and Fall 2005/2010) with 6.042J as title.

    • @ibrahimadeniji2286
      @ibrahimadeniji2286 8 ปีที่แล้ว

      Peter Reginald thanks

    • @derollo3
      @derollo3 7 ปีที่แล้ว +1

      Hello, I wanted to ask If I focus on Java programming and I would like to have a better grasp of algorithms and data structures, in order to help me in Programming, is this course appropriate for that or should I look for something different ? Thank you.

  • @naraendrareddy273
    @naraendrareddy273 3 ปีที่แล้ว +8

    I feel like the content of MIT and lower ranked institutes is the same. The difference is in the students and the delivery of the explanations.

  • @abhishekkumarsingh9938
    @abhishekkumarsingh9938 4 ปีที่แล้ว

    Buy the book CLRS. Will help you with this course. Get it here: amzn.to/2EGg3kG

  • @sober_junkie5709
    @sober_junkie5709 3 ปีที่แล้ว +2

    I feel super grateful to the free content that MIT has put up

    • @demolazer
      @demolazer 3 ปีที่แล้ว +2

      Same here. It's incredible. I've been watching lectures, revising the lecture slides, making notes, etc. All for free.

  • @matthewgale1176
    @matthewgale1176 2 ปีที่แล้ว +3

    What a comforting teacher...
    Very clear and straight remarks
    The questions of life are very import
    We will find how defaults defaults are l8fe

  • @jonsnow9246
    @jonsnow9246 4 ปีที่แล้ว +317

    All these students are the ones who say they did not study for exam and still top the class.

    • @SoumilSahu
      @SoumilSahu 4 ปีที่แล้ว +43

      Well, to be fair, you don't have to study FOR the exam to ace it. You just have to study period and that's what they do

    • @joeyGalileoHotto
      @joeyGalileoHotto 4 ปีที่แล้ว +10

      Doubt it, MIT courses are hard as hell

    • @alphaco3868
      @alphaco3868 4 ปีที่แล้ว +3

      @@joeyGalileoHotto MIT courses are quite easy....But our UN****** education system quite hard(Deep fact).

    • @mohammedjassim9250
      @mohammedjassim9250 4 ปีที่แล้ว +4

      @@alphaco3868
      Can I rely on this course to learn data structures and algorithms
      I mean we are in 2020 and this videos are before 7 years

    • @alphaco3868
      @alphaco3868 4 ปีที่แล้ว +10

      @@mohammedjassim9250 Yes you can...I recently watched this lecture __th-cam.com/video/JPyuH4qXLZ0/w-d-xo.html This lecture is about algorithm analysis. Our professors also used this technique. You understand what i'm taking about. If you complete algorithm and data structure from here & understand concept fully. I'm sure you'll find it very helpful no doubt. They also provided textbook that is available for free(.pdf)

  • @meikandanathann921
    @meikandanathann921 4 ปีที่แล้ว +9

    I really appreciate this free of cost content, because people who were not much concerning about their academics during their college days also get a chance to revisit(of course I am not speaking about MIT alumni)

  • @WhiskeredBope
    @WhiskeredBope 3 ปีที่แล้ว +2

    I LOVE how the teacher handles the syllabus!

  • @sugengsukoyo4901
    @sugengsukoyo4901 2 ปีที่แล้ว

    My master said : " GREAT TEACHER WILL ALWAYS MAKE GREAT STUDENT " So , i'm not great student , and i blame to my teacher for this .. but this is outstanding knowledge for free , wow .... Peace from Surabaya , Indonesian ..

  • @JeremyVisser
    @JeremyVisser 12 ปีที่แล้ว +4

    Excellent camera work. Wish this camera guy could film all lectures -- he handles the lecturer's walking really well.

  • @AlucardHV
    @AlucardHV 4 ปีที่แล้ว +4

    I always dreamed on going to MIT... and now I can do it from home. Thank you :)

  • @keshavjha9835
    @keshavjha9835 4 ปีที่แล้ว +7

    once you get it, that moment will make your day.

  • @falsacuenta5939
    @falsacuenta5939 ปีที่แล้ว

    0:22: 🎓 Professors introduce the course 6.006 - Introduction to Algorithms and encourage students to visit the website for more information.
    6:14: ⚙ The video discusses the use and augmentation of classic data structures and algorithms for efficiency in problem-solving.
    12:26: 🎲 The video discusses a module on numerics, including graph problems and shortest paths, with a focus on Rubik's cube assignment and finding the shortest path from Caltech to MIT.
    18:39: 📚 The video discusses building a sophisticated algorithm and characterizing its complexity in relation to the number of inputs.
    24:24: ⏰ The video discusses improving the asymptotic complexity of a one dimensional peak finder algorithm through a binary search subset approach.
    29:08: ⬆ The video explains a step-by-step process for identifying peaks in a problem.
    35:27: ⬆ The video discusses the difference between theta n and theta logn in terms of complexity, and introduces the 2D version of peak finding.
    41:47: ⚙ The video discusses implementing divide and conquer strategy for finding a 2D peak using binary search algorithm.
    47:49: 📈 The video discusses finding the global maximum in a 2D array and determining 2D peaks.
    Recapped using Tammy AI

  • @jurgenblick5491
    @jurgenblick5491 5 ปีที่แล้ว +27

    I am so glad that I found this. Been interested Algorithms for a long while.

  • @svellene
    @svellene 10 ปีที่แล้ว +1300

    I like how the chalk is soft ^_^

    • @vantalk2021
      @vantalk2021 7 ปีที่แล้ว +24

      svellene Lol Lol ASMR*

    • @jordanmoorman5024
      @jordanmoorman5024 7 ปีที่แล้ว +6

      Jill Talk literally listening to this for asmr but multitasking to get some of that brain power going too.

    • @dharmadhikariatharva
      @dharmadhikariatharva 7 ปีที่แล้ว +4

      MIT

    • @Cognitoman
      @Cognitoman 6 ปีที่แล้ว +2

      bitch I didnt ask

    • @nands4410
      @nands4410 6 ปีที่แล้ว +4

      MIT

  • @TheQuancy
    @TheQuancy 4 ปีที่แล้ว +6

    I needed this. My current algorithms class is a joke.
    For the 1st 6 weeks professor, on average, cancelled class once a week (we have classes 2x a week). Half of the 1 class we meet up, is him telling stories/making jokes. Then the whole corona virus thing hit, and we are now doing lectures online, where the first week he cancelled a class again. His current online lectures all choppy because I think he is using a laptop webcam to record him writing on a whiteboard. The quality of the videos are 240p at best, and can drop even worse at times. Looking at the syllabus, we are 4 weeks behind schedule.

    • @imjko432
      @imjko432 3 ปีที่แล้ว

      hey isn't this a little outdated? do you still find it relevant to study from this series? It was created in 2011.

  • @kingnand90
    @kingnand90 4 ปีที่แล้ว +8

    8 modules in this course:
    1. Algorithmic thinking: Peak finder
    2. Sorting and trees: Event simulation
    3. Hashing: Genome comparison
    4. Numerics: RSA encryption
    5. Graphs: Rubik cube
    6. Shortest path
    7. Dynamic programming: Image compression
    8. Advanced topic

  • @SoumyajitPyne
    @SoumyajitPyne 6 ปีที่แล้ว +1

    there is a boundary condition.if you n/2 is the left most element then there is no a[n/2-1].

    • @priyankatiwary8971
      @priyankatiwary8971 5 ปีที่แล้ว

      If n/2 is the leftmost element then we can just check with simple greater than algo...need to apply any methodology

  • @krislam2603
    @krislam2603 3 ปีที่แล้ว +1

    Watching this in quarantine... so much better than Waterloo’s voice-over slides approach for giving lectures during corona. Kinda salty that I’m paying Waterloo just to get better content for free online

  • @hansolo7988
    @hansolo7988 9 ปีที่แล้ว +95

    Wow, there's 47 of these. I love the internet :3

  • @TheNitroPython
    @TheNitroPython 3 ปีที่แล้ว +4

    So much knowledge in just an introduction course, love it.

  • @李优-n2r
    @李优-n2r 7 ปีที่แล้ว +8

    I think the professor have not explained the implication of the 1D and also 2D algorithm.
    The key is that for any 1D or 2D array there is a largest element(>= any other) and thus must have a peak. (Theory 1)
    However, in an array the sub-array's peak may not always its parent's peak if the largest element is on the edge and has a bigger element next to it. (Case 1)
    To find a peak in a sub and at the same time avoid Case 1, we must choose a larger side to ensure that even if the largest value is on edge, it is still larger than its boundary in the parent array.
    This is also why in 2D search we want a global maximum. We want to ensure that even if the max is at the boundary, it is still larger than the any element in the boundary column containing the global max we found. And thus the global max in the larger side must contain a peak.

  • @johnmacn
    @johnmacn 2 ปีที่แล้ว

    I wish the colleges and universities here had teachers like this man. They all have thick accents and do not explain in detail like this instructor. No wonder MIT has the rep it has. wow.

  • @markconley5730
    @markconley5730 5 หลายเดือนก่อน

    this lecturer is excellent and having had at least 20 different uni lecturers over the decades i should know; there are some shocking ones which oddly are the nicest characters ...

  • @rudhisundar
    @rudhisundar 5 ปีที่แล้ว +4

    This channel is a gold mine!

  • @SurfHarri
    @SurfHarri 5 ปีที่แล้ว +4

    I wish my University lecturers were so well spoken and were more interested in getting me interested in conveying excitement about the topic instead of just getting through the lecture...

  • @unhappywig
    @unhappywig 4 ปีที่แล้ว +115

    i swear youtube recommended me this. i was only looking for how to spell mathematics.

  • @lggood8375
    @lggood8375 2 ปีที่แล้ว +1

    Thanks for featuring this class. I need to know algorithms for my current computer programming learning in Python, Artificial Intelligence etc. I listen to these classes to reinforce my current knowledge.

  • @lifeviz28568
    @lifeviz28568 3 ปีที่แล้ว

    looking at this course after taking design and analysis of algorithms course as a senior this fall 2021 semester with my university. hopefully watching this video helps solidify the concepts learnt.

  • @SacWebDeveloper
    @SacWebDeveloper 5 ปีที่แล้ว +6

    One good thing about watching this at home is you don't have to answer the instructor's questions for couch cushions. =)

    • @jegie
      @jegie 4 ปีที่แล้ว

      Agree

  • @mlynskey2
    @mlynskey2 5 ปีที่แล้ว +20

    Great lecture. I'm looking forward to the rest of the series!

  • @rohitjain2910
    @rohitjain2910 9 ปีที่แล้ว +40

    Finally I figured out why he searches for a global maximum in the column instead of a local peak. It is because the peak will be guaranteed in case of a row with a number which is already a max number in a column.
    In all other cases, it will not be guaranteed. I think he left this part so that the students may think about it. In the lecture notes, he has asked this question:
    "What if we replaced global maximum with 1D-peak in Attempt #2? Would that
    work?"
    The answer is that it won`t, because the peak won`t be guaranteed. The explanation of this is that a largest element in a 1D array is definitely a peak.

    • @rohan_elysium
      @rohan_elysium 9 ปีที่แล้ว +1

      +Rohit Jain Where Can I Find The Lecture Notes?

    • @rohitjain2910
      @rohitjain2910 9 ปีที่แล้ว +7

      +Rohan Menon You can find Lecture Notes, Transcripts etc. at this link goo.gl/vkxGVS

    • @raz0rstr
      @raz0rstr 9 ปีที่แล้ว

      +Rohit Jain Can you pelase explain step-by-step what's happening? So
      1. We pick a middle column and find the global max( this guarentees that there is a peak in that specific column?)
      2. Then what? You comepare the values to the right/left of that specific peak?

    • @rohitjain2910
      @rohitjain2910 9 ปีที่แล้ว +16

      +Toiletwifi
      1. We pick the middle column and find the global max in that column. Lets call it x
      2. We compare x to its left cell and right cell.
      3. If both left and right are smaller than or equal to x, then x is the peak, otherwise we proceed to step 4
      4. if left cell > =x, then we now perform the same operation on the grid on left portion of column containing x otherwise the right portion.
      5. We peform this operation recursively, at some point, either we will find a peak in the process on a x or we will be left with only one column.
      6. If we are left with only a single column, then the global max of that column will be a peak.
      Essentially what we are doing is:
      1. We are ensuring that we are always narrowing our scanning area by half in each iteration, always moving towards the side containing a number greater than the max of middle column.
      2. This ensures that either we get a peak in the process or we are left with a single column which has atleast one value that is >=its adjacent values (because it is greater than the global max of the adjacent columns.)
      3. Now before we were left with a single column in the end, we now know that this column has a value (say y) larger than the global max of the adjacent columns . So even if there is a value greater than y in our single column, it would surely be greater than its adjacent values and is therefore a peak.
      This last point is most crucial to understand, and can be understood more clearly with help of self designed examples and following this algo.

    • @raz0rstr
      @raz0rstr 9 ปีที่แล้ว

      Rohit Jain Thanks for the explanation bro! Sorry I just started coding/algos, things come slow to me. I understand everything up to step 3.
      So I'm still a bit confused. For step 4. let's assume x =10 and left cell=20 (assuming left cell > =x), we are now in that coloumn containing 20. Now what's the next step. We check that WHOLE coloumn ( the one with the 20) and find a global max. And then look to left and right cell. THen repeat until we find a peak? So we have to find a global max in every coloumn ( assuming step 3 doesn't work out). Please explain in baby words/example, how this will guarentee a peak. Sorry once again for my dumb understanding question

  • @techiesubba1225
    @techiesubba1225 6 ปีที่แล้ว

    Long live MIT, providing this content for free. It's pure gold for someone like me from a third world country.

  • @davidledger5941
    @davidledger5941 5 ปีที่แล้ว +1

    If the peak that particular peak dataset is always a pyramid shape then its constant time.
    Check 2 points on either end of the array and then find the intercept of the two resultant lines, that is x intercept of the two lines is the index that the peak is in the array.
    The limits of this approach are the precision of the numerical calculations.

  • @touhidulislam9871
    @touhidulislam9871 5 ปีที่แล้ว +3

    this is my great fortune to have a class of MIT, its amazing to particpate in it☺☺

  • @ryanchiang9587
    @ryanchiang9587 6 ปีที่แล้ว +6

    computer science undergrad major core courses: calculus, linear algebra, discrete mathematics,
    data structure, assembly language, operating systems, and algorithm,...etc.

  • @wireboard6175
    @wireboard6175 3 ปีที่แล้ว +3

    Thank you MIT for sharing videos! They are incredibly useful.

  • @ouaremoualid4883
    @ouaremoualid4883 5 ปีที่แล้ว +1

    It is very awesome that we can follow a great courses from great institutions like MIT for free .

  • @sandeshpatil7664
    @sandeshpatil7664 3 ปีที่แล้ว

    MIT teaching faculty is extraordinary .

  • @kavindugithmin282
    @kavindugithmin282 3 ปีที่แล้ว +6

    When I read the comments I saw there were some people with a confusion about peak finding.I think It's better to know that he was not finding the "Highest Peak". He was just finding "A Peak". correct me if I am wrong.

    • @mhdsbk
      @mhdsbk 3 ปีที่แล้ว

      i think so

  • @maresfillies6041
    @maresfillies6041 10 ปีที่แล้ว +69

    Damn, I wish I went to MIT, this guy could teach! :) Bro....

    • @LittleBlacksheep1995
      @LittleBlacksheep1995 6 ปีที่แล้ว +9

      IDK why but I'm fascinated over the thought of fighting my way into MIT. The chances are not high at all, but I wil give it my best shot.

    • @BreakTheBeat852
      @BreakTheBeat852 5 ปีที่แล้ว +4

      Minh Phúc Nguyễn You can do it man, if you haven’t already

    • @toxicvoid0663
      @toxicvoid0663 5 ปีที่แล้ว +2

      @@LittleBlacksheep1995 did you get it?

    • @freeeagle6074
      @freeeagle6074 4 ปีที่แล้ว +2

      All the other professors like linear algebra and discrete math et al are fabulous professors. They make math and CSA not hard and interesting.

    • @willz17-DRX
      @willz17-DRX 4 ปีที่แล้ว

      @@LittleBlacksheep1995 any update?

  • @tommm7377
    @tommm7377 3 ปีที่แล้ว +8

    I'm not understanding the complexity of the 2D peak algorithm (@52:41). Shouldn't I have: log2(m)+1 terms "O(n)" ?
    For example with m=2: T(n,2) = T (n,1) + O(n) = O(n) + O(n). Here I have 2 O(n) that is log2(2)+1.
    Thanks in advance if you can help me to figure this out.

    • @Cypekeh
      @Cypekeh หลายเดือนก่อน +1

      In big O notation you only care about the most complex term, log2(n) has higher complexity than 1, so you just ignore 1
      Watch the lectures "Mit 6.042J Mathematics for Computer Science, Fall 2010"
      Or read about asymptotic notation

  • @TheseOfWe0112
    @TheseOfWe0112 2 ปีที่แล้ว

    A whole course focused solely on algorithmic analysis?! With two amazing professors co-lecturing?! This is why MIT reached is the global leader in post-secondary STEM education.

  • @huntersparky7446
    @huntersparky7446 5 ปีที่แล้ว

    Prof. Srini Devdas is Indian..
    Proud💪💪

  • @awaisn
    @awaisn 7 ปีที่แล้ว +4

    Lecture *starts* at 15:25
    😉

  • @butifarra61
    @butifarra61 10 ปีที่แล้ว +81

    it is free and I thank you...

    • @HuseyinKaanKoyukan
      @HuseyinKaanKoyukan 7 ปีที่แล้ว +9

      Unfortunately not.. You have to pay the online tuition fee to this bank account 32423545464566

    • @balipavankalyan5008
      @balipavankalyan5008 6 ปีที่แล้ว +2

      Hehehe

  • @rronsherifi4210
    @rronsherifi4210 5 ปีที่แล้ว +4

    This lecture made me reconsider going to Computer Science. Hard af

  • @amanarora6706
    @amanarora6706 19 วันที่ผ่านมา

    FYI - Since the array is not sorted - For One Dimensional Array the Binary Search algorithm works with some constraints like: nums[i] != nums[i + 1] for all valid i

  • @DonnaMiller-h9c
    @DonnaMiller-h9c ปีที่แล้ว +2

    Классный канал, от подачи не устаёшь

  • @warunparker4061
    @warunparker4061 7 ปีที่แล้ว +8

    Holy shit at 19:50 and Greater that guy's question of why "if it exists" was amazing the Prof had to manage something to make up for it.. Think about this >= is there then it means there DEFINITELY exists a peak. Then why "find a peak if it exists" beautiful man beautiful!

    • @fahrradflucht
      @fahrradflucht 6 ปีที่แล้ว

      I didn't understand why this has to be the case. If I have an array like [6,5,4,3,4,5,6] does this mean we have peeks at the ends? because technically we can not really compare the 6s to anything...

    • @Rohan20103
      @Rohan20103 6 ปีที่แล้ว

      @@AnilKumar-xq5mc Why the hate? He's just excited to learn... I don't see how that's bad.

  • @SarkhanRasullu
    @SarkhanRasullu 5 ปีที่แล้ว +6

    This medium article explains the same of the video. Who wants to read can use:
    medium.com/@rabin_gaire/algorithmic-thinking-peak-finding-ad6f7415d154

  • @rockypalmer6779
    @rockypalmer6779 4 ปีที่แล้ว +4

    "Peak finding" is just a fancy name for finding the max value of an ANALOG continuous function. It won't work for a DIGITAL or discrete function. Only useful for processing some things.

    • @theJasin
      @theJasin 3 ปีที่แล้ว

      Its literally the same concept for a DT function? Look into Signals / Signals and Systems it will teach you more about these subjects.

  • @luctrollsaur5644
    @luctrollsaur5644 4 ปีที่แล้ว +1

    I love these videos because it shows you that your local land grant university has the same quality of education. It's the choices you make as an individual that define your career :)

  • @pahvalrehljkov
    @pahvalrehljkov 4 ปีที่แล้ว +2

    this guy seems like a really experienced teacher...

  • @MrCarburettor
    @MrCarburettor 4 ปีที่แล้ว +3

    Omg he explains everything into great detail even related to class or not. Makes me feel bang my head to the wall.
    25:55 This is a cushion for the ones in the class only. Not for the ones watching online. Only for the ones answers non trivial questions, trivial question answers won't get it. I will throw it to you, if someone else catches give it to him. If it hits your head it doesn't hurt...
    He doesn't talk but writes algorithm... I guess this is side effect of coding. You start mumbling about possibilities you have to cover. :)
    You don't need common sense when this guy talks he will explain to you case by case..

    • @saurabhsingh-xi7nk
      @saurabhsingh-xi7nk 4 ปีที่แล้ว

      You Know from where we can access implemented code in python of algorithms discussed in lecture

  • @study7691
    @study7691 5 ปีที่แล้ว +26

    Great lecture! Just wished the cameraman wasn't in love with back of professors head!!!

  • @indrajeetjoglekar1657
    @indrajeetjoglekar1657 10 ปีที่แล้ว +63

    How in the world does the binary search like algorithm help with the 1 dimensional peak finder algorithm? The array may not be sorted..Confused.

    • @ksceriath8346
      @ksceriath8346 10 ปีที่แล้ว +8

      It might seem counter-intuitive.. but it works.. Using approach similar to binary-search, only gives an indication of which direction to proceed in... You, eventually, might not end up at the peak your previous binary-search comparison was indicating to...
      Its like saying that, 'if at i, the array is sloping up towards left, then there must 'definitely' a peak somewhere towards the left.. whereas its 'possible' that I might not find one if I go towards right.. So, now lets look at [left/2] ...' ...and so on.

    • @warrenyazzie9975
      @warrenyazzie9975 10 ปีที่แล้ว +45

      As 25:30 the professor states that he is not looking for THE peak, he only wants to find A peak. It does not matter which peak he finds, just find one. It should be understood that the algorithm he is discussing is not intended to search through a sorted list. It's intended to search through an unsorted list of "real-world" values. The lists this algorithm is for will have one or more peaks of which he is only concerned with finding one arbitrary peak.

    • @rockwithyou2006
      @rockwithyou2006 10 ปีที่แล้ว +54

      If the array was sorted, the complexity for finding a peak would be O(1). The last element :D

    • @TabmansTube
      @TabmansTube 10 ปีที่แล้ว +8

      binary search itself is not being used but the technique of splitting array into halves on every next step is being used (which is the same technique that binary search uses) + the problem is to find 'any' arbitrary peak

    • @warrenyazzie9975
      @warrenyazzie9975 10 ปีที่แล้ว +9

      Murali Mohan
      You either did not watch the video or did not understand what was explained in the video. That IS what the professor is telling the students to do. The algorithm he is describing is NOT looking for the highest number in the set. He is only looking for a peak relative to a random starting position.
      As the professor states early in the video, this class is an introductory course in programming and algorithm design. It is not intended for students who already have experience with programming. It is intended for students who have no experience. The example he provided is intended to give students new to programming a fundamental idea of how an algorithm works.

  • @AnujGupta-ee8dx
    @AnujGupta-ee8dx 6 ปีที่แล้ว +1

    Took some time to realize why he found the global max. Try for A = [ [12, 15, 16, 27], [10, 8, 3, 28], [9, 7, 25, 26], [8, 6, 2, 3] ]. In first iteration j will be 2nd column of A, in next iteration j will be 3rd column of A, and in final iteration j will be 4th column of A. Answer = 28. Realize, as we move from 2 --> 3 column, the condition checked was 15(max of 2nd)

  • @websoftwaredeveloperijtiha3093
    @websoftwaredeveloperijtiha3093 2 ปีที่แล้ว

    It's so cool that these top schools release courses like this one online free of charge. I may not get a chance to go to MIT

  • @TuxMan20
    @TuxMan20 7 ปีที่แล้ว +3

    I'm so used to Prof. David J. Malan's lectures that by putting the speed to 1.25, I felt just at home 😜

  • @FknifePK
    @FknifePK 11 ปีที่แล้ว +5

    Well, knowledge of basic algorithms and data structures is definitely a must for every programmer, but its just a small part of "a bigger picture". You should also be familiar with Web technologies, programming languages, frameworks etc. Also remember that "technology aspect" wont make your website successful if you do not have a GOOD IDEA (which targets people's needs), marketing and promotional side etc. Good luck :)

  • @lanci2154
    @lanci2154 3 ปีที่แล้ว +3

    34:34 Why are we gonna do O(1) log2n times and not n times? Where does log2n come from? I'm sorry if this is a silly question, I just don't get it no matter how much I think about it.

    • @Cypekeh
      @Cypekeh หลายเดือนก่อน +1

      If you for example start with an array of 32 elements, then in the worst case you're going to divide into subarrays of length: 16, 8, 4, 2, 1
      So for 32 elements you have to divide it at most log_2(32) times
      For n elements you have to divide the array into subarrays at most log_2(n) times

  • @shahjahansheikh9189
    @shahjahansheikh9189 5 ปีที่แล้ว +2

    i guess professor belongs to india,really its proud moment,thanks for providing us lectures free of cost.

  • @ramsmallkay
    @ramsmallkay 8 หลายเดือนก่อน +1

    FYI.... For One Dimensional Array the Binary Search algorithm works only on a Sorted Array.