Intro to Algorithms: Crash Course Computer Science #13

แชร์
ฝัง
  • เผยแพร่เมื่อ 2 ต.ค. 2024
  • Algorithms are the sets of steps necessary to complete computation - they are at the heart of what our devices actually do. And this isn’t a new concept. Since the development of math itself algorithms have been needed to help us complete tasks more efficiently, but today we’re going to take a look a couple modern computing problems like sorting and graph search, and show how we’ve made them more efficient so you can more easily find cheap airfare or map directions to Winterfell... or like a restaurant or something.
    Ps. Have you had the chance to play the Grace Hopper game we made in episode 12. Check it out here! thoughtcafe.ca/...
    CORRECTION:
    In the pseudocode for selection sort at 3:09, this line:
    swap array items at index and smallest
    should be:
    swap array items at i and smallest
    Produced in collaboration with PBS Digital Studios: / pbsdigitalstudios
    Want to know more about Carrie Anne?
    about.me/carri...
    The Latest from PBS Digital Studios: www.youtube.co....
    Want to find Crash Course elsewhere on the internet?
    Facebook - / youtubecrash. .
    Twitter - / thecrashcourse
    Tumblr - / thecrashcourse
    Support Crash Course on Patreon: / crashcourse
    CC Kids: / crashcoursekids

ความคิดเห็น • 776

  • @CaptNSquared
    @CaptNSquared 7 ปีที่แล้ว +2052

    3:53 "N Squared is not particularly efficient."
    There's no need to get personal...

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

      Snerk....

    • @Elesario
      @Elesario 7 ปีที่แล้ว +23

      It's hip to be square ;)

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

      Hey, still beats N!

    • @ayaghsizian
      @ayaghsizian 7 ปีที่แล้ว +14

      Haha that's ur real name that's so funny

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

      At least it's not O((N+1)!)

  • @xMaverickFPS
    @xMaverickFPS 7 ปีที่แล้ว +702

    this stuff is so damn interesting to me...
    but it makes me want to smash my face through a brick wall.

    • @sam-zg5ke
      @sam-zg5ke 4 ปีที่แล้ว +7

      Tickleshits go for it 🔥

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

      The pinnacle of interest.

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

      This is my homework 😔

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

      There's always a more fundamental lesson or simpler idea somewhere out there to help you understand! If this were my very first video (not assuming that it's yours) on coding, It would be a little frustrating to absorb... I've actually been binge-watching courses and documentaries on computer science all weekend, and it's just been enlightening.

  • @anandananda2277
    @anandananda2277 7 ปีที่แล้ว +67

    The good thing about computers is that they do what you tell them to do. The bad news is that they do what you tell them to do.
    ~Ted Nelson

  • @cholten99
    @cholten99 7 ปีที่แล้ว +622

    Odds of a developer being asked to write an algorithm as part of a coding interview - 75%. Odds of same develop ever writing an algorithm in their job as opposed to reusing a system library - 10%.

    • @rmsgrey
      @rmsgrey 7 ปีที่แล้ว +49

      Only if by "write an algorithm" you mean "write code that implements a named algorithm". Any code is (an expression of) an algorithm...

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

      I think he meant to re-write

    • @EddieSaleh
      @EddieSaleh 5 ปีที่แล้ว +58

      Usually researchers and people in academia are tasked to write (author) algorithms. The rest of us programmers build on top of the generally published and existing knowledge of algorithms, which mostly is already implemented in an open-sourced lib. However, it is necessary to understand the underlying steps in those libs to be able to make a good judgement on how to use them

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

      Odds of the developer writing accidentally quadratic code: 1 - epsilon

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

      Academia is Lonely. Ignored by everyone.

  • @wasimraja2980
    @wasimraja2980 5 ปีที่แล้ว +1062

    Watching in 0.75x speed !

    • @luiselpro007rgz6
      @luiselpro007rgz6 5 ปีที่แล้ว +14

      Omg y wish you luck

    • @brokeperson7103
      @brokeperson7103 5 ปีที่แล้ว +23

      thanks for the save man :)

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

      @@brokeperson7103 welcome 😃

    • @forMacguyver
      @forMacguyver 5 ปีที่แล้ว +33

      You've got a great point but try 2x speed, much more entertaining 😆

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

      me too, she talk way too fast and I cant keep up

  • @wheezyair
    @wheezyair 7 ปีที่แล้ว +543

    I can't believe this is free online to watch and learn you guys are doing great things. I deafinetly want to be a computer scientist now

    • @AdmiralWen
      @AdmiralWen 7 ปีที่แล้ว +15

      Have you checked out the Coursera class on algorithms hosted by Princeton?

    • @jakedcruz7057
      @jakedcruz7057 7 ปีที่แล้ว +22

      A lot of people are out there that want to help people learn or just give people stuff for free. That't the entire open source community.

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

      Yup they are certainly giving all this knowledge for free.
      Thank you!

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

      Don't!

  • @nohero23
    @nohero23 7 ปีที่แล้ว +96

    In school I had to write a bubble sort in 16bit intel ASM. It worked, was efficient and was well documented. It got me an A+. Even like 15 years later, I am so damn proud of that piece of code. :-D

  • @hyees13
    @hyees13 11 หลายเดือนก่อน +7

    Holy crap, homegirls an algorithm herself. Slow down

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

    Girl you are good but please take a breath, you are going fast, being English my second language, I would love to understand you. keep up the good work ;)

  • @unvergebeneid
    @unvergebeneid 7 ปีที่แล้ว +39

    "I laugh at your puny algorithms!" says Littlefinger as he transports instantly from Highgarden to Winterfell.

  • @xXAkirhaXx
    @xXAkirhaXx 7 ปีที่แล้ว +527

    Did you just say "I'll CPU later?" GET OUT.
    Just kidding terrible jokes are the mark of great computer scientists.

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

      I expect an outtake with giggling from it.

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

      Jeff Bond For a chemist, all the chem jokes are gone.

    • @xXAkirhaXx
      @xXAkirhaXx 7 ปีที่แล้ว +17

      Guys, there are 11 types of programmers in the world. The ones that get it, the ones that don't, and the ones that google it.

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

      There's 10 types of peope in the world.
      Those who understand binary jokes, those who don't, and those who didn't expect this to be a ternary joke.

    • @shehr-yar7135
      @shehr-yar7135 7 ปีที่แล้ว

      When does she say this

  • @asp-uwu
    @asp-uwu 7 ปีที่แล้ว +179

    "I'll CPU Later"
    Now I think science _has_ gone too far.

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

    *brain.exe stopped responding*

    • @devi_buns
      @devi_buns 5 ปีที่แล้ว +17

      Damn...mine crashed at the 1st quarter 😂

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

      Mine too 😂

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

      Fire Nation Files same here, man this coding stuff is way too tough for me

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

      @@goofball9292 Mind you that this course doesn't expect you to understand the details of the algorithm used, just the big picture. We have to look for a more detailed course to understand it more clearly. By then, you can only decide if coding is too tough for you or not.

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

      @@goofball9292 I'm starting out and I just keep reminding myself to learn a bit every day. I've been disheartened so many times but turns out everyone is the same.

  • @SilverMiraii
    @SilverMiraii 7 ปีที่แล้ว +72

    This series is a great addition to learning computer science, i.e. learning syntax, logic, algorithms.
    It gives context to everything, besides, it's fascinating.

  • @charntechakraisri6302
    @charntechakraisri6302 ปีที่แล้ว +32

    I learn much more in 7 minutes here than 3 hours at university.

  • @paruby
    @paruby 7 ปีที่แล้ว +21

    Small bug in pseudo code for selection sort at 3.11: third from bottom line should say "swap array items at i and smallest".
    (Currently it says to swap items at index and smallest. Since index would be at the end of the array whenever that line is executed as it is after the inner for-loop, this would swap the last and smallest elements rather than putting the smallest element in its correct position)

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

    Wow CaryAnne. I dont think a better explanation at the speed that you delivered exist anywhere. Thank you.

  • @ryann5568
    @ryann5568 7 ปีที่แล้ว +38

    Blah. Reminds me of all the interviews for Amazon and Microsoft I had to do. Not as much fun to do when you're nervous and have someone watching.

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

      How did your interviews go?

    • @KokahZ777
      @KokahZ777 5 ปีที่แล้ว +16

      @@troyh8461 he invented an algorithm to teleport

  • @tellingfoxtales
    @tellingfoxtales 7 ปีที่แล้ว +56

    Well, I guess I'm going to have to learn maths now.

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

      @@jonathanjrod yeah not really lol.
      That is when you are programming simple stuff.
      Once you get to a level that is required in big company a decent maths level is almost required. Especially discrete math.
      Then also if you wanna make AIs, that takes quite a lot of maths

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

    This episode brings back memories of university classes/lectures, wish my professors were this good though :P

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

    greater series .
    one small remark about Dykstra 's algorithm.
    it does NOT end like shown.
    the algorithm continues until the destination is the node that gets checked (so it is the smallest not checked node)
    that this is needed can easily be shown with a little modifications.
    the last step shown was starting at a 12 and had length 10. the next node that needs to be tested is distance 13 from the start. so if the length here is less than 9 we have a new shortest path.

    • @andrewshirley9240
      @andrewshirley9240 7 ปีที่แล้ว

      Right. To prove this, consider the case where the path from Pyke to Winterfall had a cost of less than 9. It would have resulted in a final route of length less than 22, and therefore been faster.

    • @botha42
      @botha42 7 ปีที่แล้ว

      Funny enough, when I saw an other video about Dijkstra's algorithm they made the same mistake. It seems to be common amogst computer scientist.

    • @DerUnbekannte
      @DerUnbekannte 7 ปีที่แล้ว

      the one by computerphile?

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

      It's a little nitpicky, but there was also another problem with this explanation:
      Since this graph is undirected, when you check a node you must also check it's "predecessor".
      So the method should be (from "King's Landing"):
      - Check edge of weight 5
      - New best found to "The Trident": (? vs 13)
      - Check edge of weight 8
      - Current weight of "Highgarden" lower (0 vs 8)
      - Check edge of weight 25
      - Current weight of "Riverrun" lower (10 vs 25)

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

      To be fair, they do mention that going via Pyke would take longer - they just don't show it with animation. It might have been better to have explained it more clearly rather than going through every intermediate step in detail, but they did at least bring it up...

  • @sjwimmel
    @sjwimmel 7 ปีที่แล้ว +157

    If you're interested in algorithms, you might like the channel Computerphile too.

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

      If you want to learn how to code some algorithms, I would recommend Tushar Roy

    • @richardpaul5427
      @richardpaul5427 7 ปีที่แล้ว +29

      *Computerphile

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

      and if you are a programmer and you want to get better, codingame.com is a good site, even if you thing you are an expert

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

      Check Out Treask Codie.....JUst Started!

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

      Big Up Nottingham UNI for computerphile!

  • @dandy-lions5788
    @dandy-lions5788 5 ปีที่แล้ว +4

    Not sure if it's been pointed out, but the Pyke-Riverrun-Highgarden creates an impossible triangle. No side can be larger than the sum of the other two sides of a triangle...🤔

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

      Yeah you're right !! But that's in Maths/"Trigonometry" the "InEqaulity Theorem" here she is just demonstrating an example to make understanding the algorithm easier. Triangles have nothing to do with the algorithm in these case. Even though you might need the theorem in a case where you are writing an algorithms which concerns triangles.

  • @syhusada1130
    @syhusada1130 7 ปีที่แล้ว +162

    We need Crash Curse for Math!

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

      i agree

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

      2 + 2 = 4, goddammit!!

    • @armanke13
      @armanke13 5 ปีที่แล้ว +12

      Cursed

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

      Yeah that sounds good

    • @2-dsynctium773
      @2-dsynctium773 5 ปีที่แล้ว +6

      This is technically math. Except you're mostly just reorganizing or shuffling numbers to make a clear statement

  • @asphoD3l
    @asphoD3l 8 หลายเดือนก่อน +2

    is there any videos or books about algorithms somewhat as good as this one? I'll be happy to know about them

  • @MFMegaZeroX7
    @MFMegaZeroX7 7 ปีที่แล้ว +31

    Just a few things to note about the "big-oh" notation discussed in this episode:
    In industry, "big-oh" notation alone is what is seen when discussing algorithms. However, in academia, it is a bit more in depth. O(n) is instead used to represent an upperbound (in the WORST CASE, what is this problem or algorithm). Ω(n) (pronounced "big-omega") is used to represent the lowerbound (in the BEST CASE, what is this problem or algorithm). Θ(n), prounounced "theta" (without the "big") is used to represent the tightbound (used when the big-oh is equal to the big-omega, which is the exact running time). There is also small omega and small o, but those are rarely used.
    Also, we only care about the biggest polynomial when we use this notation. So if a problem takes 5n^4 + 3n^2 + 1 to do, we just say it is Θ(n^4). We drop the coefficient and smaller terms because we only care about what happens when n is really really big.
    You may notice that earlier I mentioned algorithm or problem when describing the notation. This is because the it is often used in academia to denote all of the algorithms that exist for a problem. For example, for matrix multiplication of an n x n matrix, we have Ω(n^2), since we know that we at least need to read in n^2 values. This problem currently has O(n^2.3728639) which is the running time of an algorithm created by Francois Le Gall in 2014.

    • @flatfoot1983
      @flatfoot1983 7 ปีที่แล้ว

      Just a little remark: Θ is called "the_t_a".

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

      Thanks flatfoot! Fixed!

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

    i used to watch the video about computer programming languages of yours. that was very interesting and educational. this video also really good!

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

    This video was incredibly well done! This lady is really great at teaching material in a clear, easy-to-follow manner.

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

    There is something I don't understand. I'd be very grateful if anyone could explain it to me.
    3:14 "With this sort algorithm, we loop through each position in the array, from top to bottom, and then for each of those positions, we have to loop through the array to find the smallest number to swap. You can see this in the code, where one FOR loop is nested inside of another FOR loop. - This means, very roughly, that if we want to sort N items, we have to loop N times inside of which, we loop N times, for a grand total of roughly N times N loops ... or N squared."
    I would have thought that this algorithm would not need roughly N² runs in total, but roughly (N²)/2 runs.
    I'll try to demonstrate what I mean with an example. Say we have 4 values (2, 4, 6 and 8), and so 4 positions (A, B, C, D) for values.
    ___
    Before first run:
    _Start:
    A - 8
    B - 4
    C - 2
    D - 6
    ___
    First run:
    It needs 4 checks to find the smallest number.
    [8 goes from A to C, 2 goes from C to A]
    - total: 4 checks -
    A - 2
    B - 4
    C - 8
    D - 6
    ___
    Second run:
    Now the algorithm starts at position B. It needs 3 checks to find the smallest number.
    [4 checks + 3 checks = 7 checks]
    - total 7 checks -
    A - 2
    B - 4
    C - 8
    D - 6
    ___
    Third run:
    Now the algorithm starts at position C. It needs 2 checks to find the smallest number.
    [7 checks + 2 checks = 9 checks]
    - total 9 checks -
    A - 2
    B - 4
    C - 6
    D - 8
    ___
    Fourth run:
    The FOR circle is finished, because 4 is the end of the array.
    ______
    In total there were 9 checks.
    To use the quote from the beginning: "This means, very roughly, that if we want to sort N items, we have to loop N times inside of which, we loop N times, for a grand total of roughly N times N loops ... or N squared."
    N is in this example 4. And 4² is16. But in reality it took just 9 checks.
    ❗️16 isn't roughly 9, it's about twice the amount.
    I could imagine, that this is just some kind of writing standard, that doesn't necessarily reflect the reality.
    Or maybe, there is something I don't understand here. I don't like this doubt. Therefore, I would be very grateful to anyone who can tell me where my mistake lies.

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

    ive always loved the math behind a* for gaming as opposed to dijkstra's

  • @armorsmith43
    @armorsmith43 7 ปีที่แล้ว +126

    She'll likely cover this, but a big part of designing a good algorithm is thinking about how you will lay out the data. That was how djikstra's algorithm got improved from n^2 to n*log(n).
    "data structures" is your google keyword for the curious.

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

      Andrew Farrell I'm sure she will cover data structures since the start of this episode before taking about arrays she said we will get into how things are stored next week. And since we went over big O notation it would make sense to talk about arrays, trees and associative containers next week

    • @TheRilonator
      @TheRilonator 7 ปีที่แล้ว

      Good call.

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

    Best one in the series so far. . .imo

  • @umidnazarov5725
    @umidnazarov5725 7 ปีที่แล้ว

    I like the way you named nodes.I will do the same.

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

    The solution in this example is obscenely overly complicated. The mark of an entry-level design.

  • @AvailableUsernameTed
    @AvailableUsernameTed 7 ปีที่แล้ว +397

    I thought algorithms were invented by Al Gore.

    • @germanaldaysalazar565
      @germanaldaysalazar565 7 ปีที่แล้ว +30

      It's Al Gore's pace. Al Gore Rhythm (I'll kms now)

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

      Still better than "I'll CPU later."

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

      Pipe2DevNull damn man lol everyone replying to you has has some deep senses of humor. 👍

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

      Invented is a big word,
      al gore invented just the ManBearPig

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

      Al Gore only invented the global warming

  • @danielgronbjerg
    @danielgronbjerg 7 ปีที่แล้ว +36

    I'm amazed how much ground you're able to cover in less than 12 minutes.
    To be fair, if you haven't heard most of this before you would probably need the video to be twice as long to get anything from it, but even then I would be impressed with how much was stuffed in there.
    Keep up the good work!

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

      Watching at 0.75x, and still pausing many times to see the frame, take in and process the information

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

    I always found algorithms to be the most interesting part of computer science.
    This video was great, but it of course only scratches the surface.
    Next up: Data Structures???

    • @Grimlock1979
      @Grimlock1979 7 ปีที่แล้ว

      Yah! I got it right!

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

    Your tutorial so bright to me, thank you so much 😊

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

    My favorite algorithm is hybrid sort, it's literally a hybrid of counting sort and quick sort

  • @Jackscin
    @Jackscin 7 ปีที่แล้ว

    I like just subscribed to the channel and I feel like a new, smart person

  • @MK-ji9ke
    @MK-ji9ke 7 ปีที่แล้ว +1

    Nice video.
    Quick question about the Dijkstra example. If the weight of the road between Pyke and Winterfell was 8 instead of 18 then Highgarden->Riverrun->Pyke->Winterfell would be the better route. Would Dijkstra's algorithm continue looping to find this pathway?

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

    So interesting but now I'm getting a headache trying to do the math D: lol

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

    When I was youger(in elementary school) is would sometimes sort all couple hundred of my Pokémon cards or Yugioh cards, this episode talked about sorting and it out into perspective that sorting cards in less time should require a balance of swapping cards and thinking when sorting other things are very different(I was weird, I think)

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

    Computation is the basic of all the science.

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

    It bothered me that the lengths of those triangles are impossible but then I remembered it's a map and the longer lengths can be explained with mountains. I can sleep in peace now.

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

    You finished Dijkstra's algorithm once you found the first path to Winterfell, but in reality you should wait until Winterfell is the node with the lowest cost which has yet not been searched from. In the example, if the cost of the road from Pyke to Winterfell was 1, the shortest path would actually be through Pyke to Winterfell in 14 weeks, which you would find if you ran Dijkstra one more time from the cheapest unexplored node which was Pyke.

  • @alielahinik8663
    @alielahinik8663 5 ปีที่แล้ว +17

    High quality content.. but why the rush? (almost all the videos from this channel sounds like eminem rapping) let the brain soak the info.

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

    I'm so glad I found this channel. You explain everything so well! Thank you! :)

  • @ianrbuck
    @ianrbuck 7 ปีที่แล้ว

    Am I correct in thinking that Dijkstre's algorithm doesn't guarantee it finds the best path? In their example, they never checked the connection between Pyke and Winterfell, which could conceivably have resulted in a faster route than Riverrun->Trident->Winterfell.

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

    Thank you for mentioning alkhawarzimi because allot of us don't know him but we admire him

  • @sboochek
    @sboochek 7 ปีที่แล้ว +5

    episodes 7-12 I was totaly lost, finally i start to understand again a little

  • @GMODISM
    @GMODISM 7 ปีที่แล้ว

    Great video! Made me catch up the class I almost understood! ^___^

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

    *_"AL-OW-WRIT-TIMMYS"_*
    Me is good at grammar of english

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

      well letting an AI spell this way, requires very high *ALGORITHMS*

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

    0:51 nah that's just handsome squidward

  • @petershort3889
    @petershort3889 7 ปีที่แล้ว +47

    Easily the best explanation of Big O I've seen... better than my professor explained it last semester.

    • @rmsgrey
      @rmsgrey 7 ปีที่แล้ว +5

      With a lot of maths (and closely related subjects like the abstract end of computer science) there are two explanations for most concepts - the carefully worked out formal definition [ f(x) = O(g(x)) if there exist values w and c such that for all x>w, f(x)

    • @VladSvoka
      @VladSvoka 7 ปีที่แล้ว

      read some art of computer programming by Knuth. Great explanation there.

    • @s.r6174
      @s.r6174 6 ปีที่แล้ว +1

      Peter Short nice

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

      @@rmsgrey I don't know why people even bother teaching with the "formal" definitions and whatnot. It all just goes over my head. I guess people are just snobs looking for clout.

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

      @@Scarabola The formal definitions are also important - they're how you tell that something doesn't just seem like a reasonable idea, but actually works - so they do need to be taught at some point (and they're what generally gets tested in exams since it's easier to test whether someone can perform the formal symbol manipulation correctly than whether they understand what the symbol manipulation really means) - it's just that the other side - what the symbols mean and why things have the definition they do - is also important in the long run, and should be taught too.

  • @ProfessorSyndicateFranklai
    @ProfessorSyndicateFranklai 7 ปีที่แล้ว +19

    Who's still haunted with debugging Algorithms?

    • @Kabodanki
      @Kabodanki 7 ปีที่แล้ว

      outsourced it to chinese

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

    lol drogon flyin 7:34 was so cool...

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

    7:30 It's very strange to see The Trident put on a map as if it's a city. The Trident is a river.

  • @AlterDieg8
    @AlterDieg8 7 ปีที่แล้ว +79

    Great Game of Thrones reference

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

    Now the really important question: does Carrie Anne actually own a ceramic cat collection? :P

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

    I watched the first 24 seconds and I said "Gosh, I love you".

  • @stefanos-phoebosnahmias8736
    @stefanos-phoebosnahmias8736 4 ปีที่แล้ว

    i want to study game development and i know, in order to make a game you need algorithms, but i am not particularly good at math and sometimes when it gets too confusing, my mind gets lost. though, i am positive that i understood 65% of this video. Will i make it XD???

  • @Leotique
    @Leotique 7 ปีที่แล้ว +5

    Always feeling a bit smarter after watching Crash Course, thank you :)

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

    Finally I really like programming

    • @treaskcodie4649
      @treaskcodie4649 7 ปีที่แล้ว

      Check Out Treask Codie.....JUst Started!

  • @chillingmeko
    @chillingmeko 7 ปีที่แล้ว

    I can't believe I only found this channel just now. XD

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

    In the pseudocode for selection sort at 3:09, shouldn't the swap be ...
    swap array items at i and smallest
    instead of
    swap array items at index and smallest
    ?

    • @divinegrace92
      @divinegrace92 7 ปีที่แล้ว

      Michael Gainey I is universal for index

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

      The pseudocode uses both i and index as variables. They are both indexes -- i for the outer loop and index for the inner loop. Unless I'm wrong, the swap statement uses index when it should use i.

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

      Nice catch. You are indeed correct.

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

      and the total number of loops should be (n^2 - n)/2 , not n^2 as after each iteration of the outer for loop one element is already sorted and the total number of comparisions decreases by 1.

    • @Gobberwart
      @Gobberwart 7 ปีที่แล้ว

      No Name this was bugging me too.

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

    Best series on crash course

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

    I would love to promo your page
    Not only do more people need this kind of information. It’s vital for the future. Let me know if I could help out and maybe we can trade for skills

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

    I love your videos, keep it up!

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

    Fascinating. Thanks!

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

    0:46 Props to her!

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

    First English person who pronounces "Voilà" quite correctly :)

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

    I invented a sorting algorithm. I call it ice sort. There are n² comparisons and zero swaps, so it's great for small sets.
    for(int n: nums[]) {
    index = (count of items in nums[] that are lower than n)
    index++ until empty slot in sorted[] is found
    sorted[index] = n;
    }

  • @G.B.B.
    @G.B.B. 10 หลายเดือนก่อน +1

    Austin Powers teaches algorithms

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

    I remember Bubble Sort and Dijkstra’s algorithm when I did my A-level Decision Maths. That confused me so much but when applied to Computer Science it really makes such a significant difference and it’s weird but very interesting fun maths ! :D

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

    you taught me so much in the 90's PBS now you continue to give me knowledge. Thank you.

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

    She talks way too fast. Its easy to understand but slow down. Why is she rushing??

  • @nathanj202
    @nathanj202 7 ปีที่แล้ว

    This is great, keep up the amazing work CC
    Also 38th!

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

    She talks faster than the internet connection.. you in a hurry?

  • @lone-warrior-13
    @lone-warrior-13 5 ปีที่แล้ว

    I'm a self thought programmer and i want to study computer science in college. but I'm really bad at math specially algebra and algorithms I literally don't understand anything should I really study computer science? because a lot jobs require a university degree.

  • @AtLeastTryALittle
    @AtLeastTryALittle 7 ปีที่แล้ว

    next week we will discuss algorithms.... intrigued? you would be!

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

    Can I be a computer scientist at 62?
    (Well, I know that the best time was 45 years ago.)

  • @lopany
    @lopany 7 ปีที่แล้ว

    Awesome look, love the glasses!!!

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

    you could make a math series, it would be awesome you explain things so neatly i have literally studied of your videos to get good grades lol, it would help me get into collage cause honestly im lost when it comes to advanced complicated math. i have 5 months to learn everything and its really overwhelming and frustrating im fucked if i fail that test cause where i live if you're not a professional you wont earn more than 4 bucks an hour and thats if you're lucky

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

    7:31 I saw just that in an anime about scientists-- (and love)

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

    Ah yes, the graph: depth-first vs breadth-first search. I also quite enjoyed the binary search tree (BST). Really fascinating field of algorithms and data structures. :)

  • @withoutcommentary-kh6rx
    @withoutcommentary-kh6rx 7 ปีที่แล้ว +8

    Every TH-camr should watch this before complaining about the "algorithm".

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

      Why? People complain about the algorithm, for not sorting their videos in first because of mature content, and this proves that is what an algorithm does, sort

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

    I was surprised to hear about Dijkstra's algorithm. I've learned about that in my networking class, particularly in regard to the link-state routing protocol known as OSPF (Open Shortest Path First).

    • @s.r6174
      @s.r6174 6 ปีที่แล้ว +1

      Nice

  • @59vibhusharma31
    @59vibhusharma31 4 ปีที่แล้ว

    Algorithms aren't just about coding they are about the steps involved in solving a problem when you use a programming language to perform an algorithm then its coding.

    • @Rohit-rx5rz
      @Rohit-rx5rz 4 ปีที่แล้ว

      Please any one help. I am in 1st year 2nd semester going to finish. Now holidays due to Corona virus .I cant develop the logic of how to put the values properly and all .for eg like in pattern printing and most of the competitive problems like in codeforces and hackerank. My friends do simply all these.i dont know how to do it. What should I do. HELP.i dont know what And how to code.

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

      @@Rohit-rx5rz Well
      1. Don't be afraid of coding I mean not even professionals write working code n the first go try pondering and experimenting with different ideas
      2. Every complex problem is just a set of many simple problems I recommend you to just see a problem as a puzzle you just not pick up all the pieces and put them together you put them down bit by bit by carefully looking at each piece with focus well that's just a general tip for solving life problems.
      3. Try to reason a problem to its roots, for example, think what caused and build your logic till you don't know what caused it then learn it
      4. If knowledge is power learning is superpower so try to use Feynman technique first read something then go to a paper or your laptop and write down what you read as simply as possible wherever your teaching couldn't be understood by a fresher in programming stop and revise the topic
      Here are my suggestions well I am just 13 wish me luck

    • @Rohit-rx5rz
      @Rohit-rx5rz 4 ปีที่แล้ว

      @@59vibhusharma31 lol thanks🤗

    • @59vibhusharma31
      @59vibhusharma31 4 ปีที่แล้ว

      Welcome

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

    CPU Later! love it!! Didn;t take long to PROCESS that one! LOL

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

    whiterun _ riverrun and winterfell _ hammerfell

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

    This course is getting better - while it started out great anyway.

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

    O(n^2) is inefficient? Depends, it's pretty great when you usually deal with NP-Difficult problem. :P

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

    8:14 This is how routers build routing tables. In other words, it's how all those ones and zeroes find their way across the Internet.

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

    this is so good for review

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

    I just learned this 2 days ago in class!!!! Amazing.

  • @welearn615
    @welearn615 7 ปีที่แล้ว

    Nice tutorial!

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

    Thank you but you are talking FAST i am not from UK or US i cant understand chen you talk quickly

  • @user-be4yc2vr5c
    @user-be4yc2vr5c 5 ปีที่แล้ว

    Ok holy cow, does anyone remember "Brute Force Hacking" ? From DOS days I think?

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

    CREEPER!!!!!!!!!!
    Aaaawwwwwwwwww MAN
    so we back in the mine
    got our.....