*SEIZURE WARNING* Pushing Sorts to their Limits

Поділитися
Вставка
  • Опубліковано 16 тра 2024
  • Visit our community Discord: / discord
    Check out the NEW home for ArrayV here: github.com/gaming32/ArrayV-v4.0
    Check out the Mother 1+2 Restoration project: / discord
    Special shoutout to regibus361 ( / channel ) for doing the video's chapters!!
    EXCHANGE SORTS
    Bubble Sort - 0:00
    Optimized Bubble Sort - 0:32
    Cocktail Shaker Sort - 0:46
    Optimized Cocktail Shaker Sort - 1:09
    Odd Even Sort - 1:29
    Gnome Sort - 1:46
    Optimized Gnome Sort - 2:14
    Optimized Gnome Sort + Binary Search - 2:32
    Comb Sort - 2:59
    Circle Sort - 3:31
    QUICK SORTS
    Quick Sort, Left/Left Pointers - 5:06
    Quick Sort, Left/Right Pointers - 5:56
    Dual Pivot Quick Sort - 6:35
    Stable Quick Sort - 7:04
    SELECTION SORTS
    Selection Sort - 7:38
    Double Selection Sort - 7:56
    Cycle Sort - 8:07
    Max Heap Sort - 9:07
    Min Heap Sort - 9:42
    Flipped Min Heap Sort - 10:19
    Weak Heap Sort - 10:54
    Ternary Heap Sort - 11:26
    Smooth Sort - 12:03
    Poplar Heap Sort - 12:47
    Tournament Sort - 13:22
    INSERTION SORTS
    Insertion Sort - 13:59
    Binary Insertion Sort - 14:23
    Shell Sort - 14:51
    Patience Sort - 15:04
    Unbalanced Tree Sort - 15:27
    MERGE SORTS
    Merge Sort - 15:53
    Bottom up Merge Sort - 17:00
    In Place Merge Sort - 18:10
    Lazy Stable Sort - 19:26
    Rotate Merge Sort - 19:59
    DISTRIBUTION SORTS
    Counting Sort - 21:01
    Pigeonhole Sort - 21:12
    Gravity Sort - 21:21 (I can hardly keep up!)
    American Flag Sort, 128 Buckets - 22:05
    Least Significant Digit Radix Sort, Base 4 - 22:24
    In Place LSD Radix Sort, Base 10 - 23:00
    Most Significant Digit Radix Sort, Base 4 - 24:02
    Flash Sort - 24:43
    Iterative Binary Quick Sort - 25:02
    Recursive Binary Quick Sort - 25:36
    Shatter Sort - 26:09
    Simple Shatter Sort - 26:24
    Time Sort, Mul 10 - 26:50
    CONCURRENT SORTS
    Batcher’s Bitonic Sort - 27:43
    Batcher’s Odd Even Merge Sort - 28:46
    Recursive Pairwise Sorting Network - 29:46
    Iterative Bitonic Sort - 30:43
    Iterative Odd Even Merge Sort - 31:47
    Iterative Pairwise Sorting Network - 32:52
    HYBRID SORTS
    Hybrid Comb Sort - 33:56
    Introspective Circle Sort - 34:20
    Binary Merge Sort - 35:15
    Weave Merge Sort - 36:22
    Tim Sort - 37:14
    Cocktail Merge Sort - 38:28
    Wikisort - 39:37
    Grailsort - 40:43
    Sqrtsort - 41:54
    Introspective Sort [std::sort] - 42:57
    Optimized Bottom Up Merge Sort [std::stable_sort] - 43:29
    Optimized Dual Pivot Quick Sort [Arrays.sort] - 44:18
    Pattern Defeating Quick Sort - 44:59
    Branchless Pattern Defeating Quick Sort - 45:19
    MISCELLANEOUS SORTS
    Pancake Sorting - 46:06
    IMPRACTICAL SORTS
    Bad Sort - 47:08
    Stooge Sort - 48:10
    Silly Sort - 49:26
    Slow Sort - 52:18
    Exchange Bogo Sort - 55:07
    Bubble Bogo Sort - 55:48
    Less Bogo Sort - 56:36
    Cocktail Bogo Sort - 57:11
    Bogo Sort - 57:51
    Bogo Bogo Sort - 57:57
  • Наука та технологія

КОМЕНТАРІ • 10 тис.

  • @mr_noobx3009
    @mr_noobx3009 3 роки тому +21347

    X Æ A-12 first words are so cute

  • @jaimdiojtar6515
    @jaimdiojtar6515 3 роки тому +5166

    27:02 when the water for my tea is ready

  • @7axes
    @7axes Рік тому +676

    21:12 Pigeonhole sort is an ABSOLUTE BEAST. Sorting 16k items in just 4 MILLI SECONDS (0.0004s)

    • @menooNFT
      @menooNFT 11 місяців тому +49

      im glad im not the only one super amazed by that

    • @ImScor327
      @ImScor327 11 місяців тому +92

      Small correction, 0.004s, but it's still so damn fast...

    • @burntpyromaniac
      @burntpyromaniac 11 місяців тому +80

      It’s just: look at the thing, solve it.

    • @incription
      @incription 10 місяців тому +14

      Counting sort is faster I think they are using 14 bit numbers here

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

      @@incription no pidgeonhole is faster

  • @coldshotgg7100
    @coldshotgg7100 Рік тому +570

    I especially like the sort at 23:12 because it reminds me of my parents fighting at night when they thought I was asleep but little did they know that I was fully aware of the situation and cried myself to sleep

  • @qpauline100
    @qpauline100 3 роки тому +3119

    puts fork in microwave 22:59

  • @SawtoothWaves
    @SawtoothWaves 3 роки тому +34060

    i don't understand what's going on and at this point I'm too afraid to ask

    • @Musicombo
      @Musicombo  3 роки тому +6553

      Animations of sorting algorithms!

    • @paulomartins1008
      @paulomartins1008 3 роки тому +2716

      You write instructions computer follows instructions at the end numbers are sorted.

    • @rickybishop81
      @rickybishop81 3 роки тому +2073

      @@paulomartins1008 you sadly still didn’t dumb it down enough for me

    • @timeflex727
      @timeflex727 3 роки тому +2646

      @@rickybishop81 u write. computer do

    • @gemhunter498
      @gemhunter498 3 роки тому +993

      My guess as to what it's doing here: Those lines represent numbers. Each one is a slightly different height. The algorithm sorts these lines in different, unique ways. Each line also has a slightly different tone assigned to it, which plays when it is compared, swapped, or reversed.

  • @dustinzacharias8227
    @dustinzacharias8227 11 місяців тому +40

    Bogo bogo sort is the special one in the family. Pigeonhole sort is like, “Good job buddy, you sorted six shapes!”

  • @IL2PG
    @IL2PG Рік тому +95

    My personal favorite is 57:50, there are so many numbers that it is unimaginable that a computer could process that much. I can barely count that far.

    • @bisousethiboux
      @bisousethiboux 7 місяців тому +5

      I can only count to four.

    • @Bjoviii
      @Bjoviii 7 місяців тому

      @@bisousethibouxNo need to toot your own horn here...

    • @davidthecommenter
      @davidthecommenter 7 місяців тому +6

      @@bisousethibouxWHAT COMES AFTER ONE
      TWO
      WHAT COMES AFTER TWO
      THREE
      WHAT COMES AFTER THREE
      FOOOOUUURRRRR
      I CAN ONLY COUNT TO FOUR
      I CAN ONLY COUNT TO FOUR
      I CAN ONLY COUNT TO FOUR

    • @amphibiland
      @amphibiland 20 днів тому

      @@davidthecommenter w reference

  • @ncot_tech
    @ncot_tech 3 роки тому +2341

    24:43 - Step 1 - Get shuffled data, Step 2 - ???, Step 3 - Sorted.

    • @2-dcat28
      @2-dcat28 3 роки тому +4

      Lol

    • @thatoneguy9582
      @thatoneguy9582 3 роки тому +552

      21:12
      1. Read data
      2. Do the fucking thing

    • @AlexKuz
      @AlexKuz 3 роки тому +30

      Step 2 is sorting you silly)

    • @l1ttel_y699
      @l1ttel_y699 3 роки тому +36

      See that counter of Writes to Auxiliary Array? This used some external data structure that wasn't shown on screen

    • @purplepotatoes9255
      @purplepotatoes9255 3 роки тому +61

      13:23

  • @OliverMoy
    @OliverMoy 2 роки тому +14531

    I came to the video like "huh?'
    and left the video like "oh."

  • @dolger4308
    @dolger4308 Рік тому +549

    Shortest sort: 3.7ms (Pigeonhole[21:11]). Longest sort: 40.9s (Time Sort, Mul 10[26:49]). Honerable Mention: Silly Sort (572,566,806 Comparisons[49:26]).

    • @Your_favorite_seasoning
      @Your_favorite_seasoning Рік тому +36

      Actually, longest sort is circle sort, 67.5s

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

      Thanks for this.
      Man, silly sort is an idiot

    • @odanedmcdonald
      @odanedmcdonald Рік тому +7

      @@Your_favorite_seasoning Thanks please for timestamp

    • @Your_favorite_seasoning
      @Your_favorite_seasoning Рік тому +13

      @@odanedmcdonald np!
      Circle sort: 3:31

    • @odanedmcdonald
      @odanedmcdonald Рік тому +41

      @@Your_favorite_seasoning Much thanks bro/sis. That's 67.5 milliseconds, simple mistake.

  • @CutThroxt
    @CutThroxt Рік тому +147

    I didn't realize how fast it was actually completing the sorts until I saw that the time it took for each one to be completed was mere milliseconds. Honestly astounding

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

      Except BOGO BOGO sort

    • @uuproverlord8324
      @uuproverlord8324 8 місяців тому +4

      Sort() is fastest

    • @bomblii
      @bomblii 16 днів тому

      look at time sort at 26:50

  • @ghsclklkgpbchjj1550
    @ghsclklkgpbchjj1550 2 роки тому +1743

    21:13 when you complete a round in a 90's game

    • @deja-vu6279
      @deja-vu6279 2 роки тому +12

      SO TRUEEE

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

      JSJJAJAJAHAHHAHAHAHA

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

      @@deja-vu6279 shut up

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

      Was it not just the pinball on windows 97 or something

    • @Papasmurf-sm5nk
      @Papasmurf-sm5nk 2 роки тому +12

      @@fruitsn4ck you shut up

  • @yatzeegamingop
    @yatzeegamingop 3 роки тому +732

    57:55
    It just shuffled 6 numbers 200 million times to get it right...

    • @hairyputter5363
      @hairyputter5363 2 роки тому +173

      That's bogo bogo. The ultimate Chad of sorting methods

    • @nuyabuisness7526
      @nuyabuisness7526 2 роки тому +102

      6 possibilities in 6 positions. approximately 46 thousand possible outcomes. Is there a way for an efficiency number to be negative? I think being 2000 times less efficient than literal brute force testing has got to be a record.

    • @zevinneve
      @zevinneve 2 роки тому +11

      Why does it suck so much? What use could it possibly have?

    • @astolfo11
      @astolfo11 2 роки тому +68

      @@zevinneve the use is showing how bad it is of a sorting algorithm. Its just a joke algorithm, no practical use

    • @hairyputter5363
      @hairyputter5363 2 роки тому +10

      @@yosemite963
      That's not how permutations work.
      6 objects 6 places. Total outcomes (arrangement) = 6^6 =46566

  • @ManosSef
    @ManosSef 8 місяців тому +13

    At this point I'm convinced that people make new sorting algorithms just for these visualizations.

  • @cflam1
    @cflam1 Рік тому +368

    Best Picture Awards:
    Iterative Pairwise Sorting Network (32:51)
    Recursive Pairwise Sorting Network (29:46)
    Gravity Sort (21:23)
    Best Music Awards:
    Exchange Bogo Sort (55:07)
    Grailsort (40:43)

    • @Zellebobba
      @Zellebobba Рік тому +18

      My personal favorite in Picture award: Gravity sort

    • @nileprimewastaken
      @nileprimewastaken Рік тому +6

      i like the iterative bitonic sort

    • @Ell0_sTadium66
      @Ell0_sTadium66 Рік тому +2

      LSD Radix sort was cool, but not it's in-place variant...

    • @zhaqihanifah4915
      @zhaqihanifah4915 Місяць тому

      @@nileprimewastaken it's literally Moog City

    • @jackcomas
      @jackcomas 2 дні тому

      @@Zellebobba everyone loves Gravity Sort

  • @nohintshere
    @nohintshere 2 роки тому +6084

    me: "i'm not a robot"
    also me: "damn these sorting algorithms slap"

  • @AnotherYouTubeUser581
    @AnotherYouTubeUser581 2 роки тому +6391

    mom: Go outside and play with the neighbors kids, they arent that bad
    the neighbors kids: 23:03

    • @elonleon4452
      @elonleon4452 2 роки тому +202

      I remember the neighbours kids flying at piss of miles per hour.
      Good times.

    • @pixelcat29
      @pixelcat29 2 роки тому +98

      POV: you have Elon musk as a neighbor

    • @jacks248
      @jacks248 2 роки тому +20

      @Noel Noel what does that even mean

    • @Cheese-fp8dy
      @Cheese-fp8dy 2 роки тому +51

      Your neighbor is a printer?

    • @perhapsclem872
      @perhapsclem872 2 роки тому +27

      @@Cheese-fp8dy seems like a thing Niko would say.

  • @mbmd_nation
    @mbmd_nation Рік тому +37

    Thank you for giving Bogo sort a chance 🙏🏻

  • @cole2999
    @cole2999 Рік тому +18

    Nothing could have prepared me for 9:42

  • @ominous_fox704
    @ominous_fox704 2 роки тому +576

    my sanity during the day: perfect amazing outstanding
    my sanity at 3am: 23:40

  • @hamadcheats
    @hamadcheats 2 роки тому +2927

    *_27:10_**_ That actually sounded like a haunted teapot._*

    • @Blockistium
      @Blockistium 2 роки тому +123

      Polteageist!

    • @variegatus4674
      @variegatus4674 2 роки тому +24

      @@Blockistium Give us a sign!

    • @quill7889
      @quill7889 2 роки тому +17

      @@Blockistium I found the funny

    • @rkoislife1738
      @rkoislife1738 2 роки тому +11

      nah sorry g i farded

    • @Mona-.-
      @Mona-.- 2 роки тому +4

      Do u mean kettle or am I dumb

  • @Levi_The_One_The_Only
    @Levi_The_One_The_Only Рік тому +28

    Holy crap I just realized why I liked listening to these so much and why I keep coming back to this video to listen to in the background: the sound it makes is really good at masking tinnitus. There's a different video I watch that has a similar sound but it's specifically for masking tinnitus but I just realized how similar the sounds are.

  • @6g-radio-tower
    @6g-radio-tower 9 місяців тому +8

    my fave gotta be the gravitational sort at 21:54 no wonder plankton dated a robot

  • @bomberfish77
    @bomberfish77 3 роки тому +873

    23:56 the most anticlimactic thing ever

  • @vidlurker8906
    @vidlurker8906 2 роки тому +2734

    4:28 when a perfectionist sees something that is already clean

    • @JNJNRobin1337
      @JNJNRobin1337 2 роки тому +95

      Gotta Make Sure Its Sterilized

    • @finn_in_the_bin5263
      @finn_in_the_bin5263 2 роки тому +21

      you mean me playing viscera cleanup detail

    • @catzillapurrfect4526
      @catzillapurrfect4526 2 роки тому +60

      I know your amateur eyes cant see it, but it's a minuscule to the left.

    • @Dino-lw4mj
      @Dino-lw4mj 2 роки тому +19

      It isnt clean, you can clearly see that it is angled 2 more degrees to the right than its supposed to be, and you didnt even sterilise it

    • @nanaten3
      @nanaten3 2 роки тому +6

      I can confirm, that's me

  • @1ch0r41
    @1ch0r41 Рік тому +9

    Bubble sort and merge sorting were fun to learn. These videos make me appreciate the efficiency of certain sorting methods.

  • @ZA-mb5di
    @ZA-mb5di Рік тому +7

    10:13 finally, a reversal

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

      If you like reversals you'll LOVE 46:05, an entire sort dedicated to flipping the array until it's sorted

  • @tofidu
    @tofidu 3 роки тому +2266

    25:20 when you want the floor to be very very clean

    • @YTWstudio
      @YTWstudio 3 роки тому +160

      then a cat come by: 57:57

    • @peejar2175
      @peejar2175 3 роки тому +28

      except you forgot about the leftover line of dirt outside of the dustpan

    • @zthehuman7051
      @zthehuman7051 3 роки тому +26

      Also comb sort : 3:01

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

      relatable

    • @EntergeticalakaBot
      @EntergeticalakaBot 27 днів тому

      It looks like it's pentuple checking if it's all right, going slower and slower

  • @CE7341
    @CE7341 3 роки тому +6225

    "They look depressed, I wonder what they're listening to."
    The quiet kids headphones:

  • @Savitar1976
    @Savitar1976 Рік тому +9

    7:59 pacman dying

  • @alphakretin2387
    @alphakretin2387 9 місяців тому +2

    “How many sorting algorithms do you know?”
    “Sort of a lot.”

  • @harrisluo5818
    @harrisluo5818 3 роки тому +8773

    My therapist: Gradually expanding slanted histogram doesn't exist. It can't hurt you.
    Gradually expanding slanted histogram: 23:43

    • @abyssalboy8811
      @abyssalboy8811 3 роки тому +532

      It searches for blood.

    • @starfox5165
      @starfox5165 3 роки тому +420

      It knows where you are. It is expanding to your location. You cannot run. You cannot hide. All you can do is beg.

    • @Blue-jy4rf
      @Blue-jy4rf 3 роки тому +153

      That sort is the definition of anxiety

    • @MrYeet-ip4qj
      @MrYeet-ip4qj 3 роки тому +64

      It has a timestamp, I like.

    • @alexvalente9733
      @alexvalente9733 3 роки тому +94

      I genuinely laughed out loud at this. Like truly, this was the funniest thing I've experienced in a while. What is wrong with me.

  • @memekeeper-gaming3552
    @memekeeper-gaming3552 2 роки тому +624

    "What is bogosort doing?"
    "Its best"

  • @Calameggy
    @Calameggy Рік тому +29

    23:43 sounds like a sound that builds up tension in a horror game

  • @ishu4227
    @ishu4227 Рік тому +15

    i like how in cycle sort the sorted array just synthesizes into existence

  • @memz9324
    @memz9324 3 роки тому +876

    23:45 *The new THX soundeffect sounds great*

  • @alexz7766
    @alexz7766 3 роки тому +1219

    0:48 POV: You're falling down a bottomless pit

    • @imsiege
      @imsiege 3 роки тому +34

      i see and hear this

    • @ShayerSUtsho
      @ShayerSUtsho 3 роки тому +53

      Falling below bedrock in Minecraft

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

      UNDERTALE

    • @ShayerSUtsho
      @ShayerSUtsho 3 роки тому +4

      @@ninjireal when it's not a pun but it's a pun

    • @zaidanhakim1072
      @zaidanhakim1072 3 роки тому +6

      all me see is vagene

  • @chattymatt
    @chattymatt Рік тому +2

    OMG it feels like it has been years since I stumbled into one of the 'weird' corners of UA-cam. I wish I would come across stuff like this more often. On my recommended page and everything!

  • @DJ-lo8qj
    @DJ-lo8qj Рік тому +8

    iterative bitonic sort just made me so happy 30:40
    the best sort is not the fastest or most memory efficient: it is the sort the places the data into visually appealing, symmetric piles
    thank you iterative bitonic sort: the hero we deserve, but not the hero we need right now

  • @tbtb66
    @tbtb66 3 роки тому +2509

    "Yo the Earthbound soundtrack slaps"
    The Earthbound soundtrack:

    • @Christine.3671
      @Christine.3671 3 роки тому +19

      It does slap tho ua-cam.com/video/spF6PuFh7y4/v-deo.html

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

      Haha *yes*

    • @sarahtonin58913
      @sarahtonin58913 3 роки тому +27

      This is even better because according to the description the uploader is a part of/a fan of the MOTHER 1 and 2 restoration project

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

      It slaps

    • @officialabnormalnightmare
      @officialabnormalnightmare 3 роки тому +7

      As a person who’s a huge fan and actually played EarthBound, I can confirm that this is true.

  • @rathors7184
    @rathors7184 2 роки тому +3969

    The Tournament Sort 13:22 is just when you been working on a problem for a while, give up and then look up the answer online.

  • @requiemforameme1
    @requiemforameme1 Рік тому +2

    As someone who enjoys memorizing primary keys on legacy SoR tables to the point they can whiteboard out near-usable SQL… this entire video is very calming to me. :)
    “Ahh… no pagination issues. No sharing the processing queue. No read, all write, all right.”

  • @lolzorgfykys
    @lolzorgfykys Рік тому +3

    the ones that go from lowest to highest frequencies are interesting because when you get to the middle-high range it starts to sound like a kettle boiling

  • @SarcasticCupcake223
    @SarcasticCupcake223 2 роки тому +876

    This is probably the strangest, "out of the blue" thing UA-cam had ever recommended me, but its oddly entrancing...

  • @fahrenheit2101
    @fahrenheit2101 2 роки тому +1116

    4:27
    When you've already tidied your room but you have nothing else to do so you convince yourself its still messy to take up time.

  • @Rooftopaccessorizer
    @Rooftopaccessorizer Рік тому +2

    every once in a while i stumble on a new hobby ive never heard of before and this is one of them

  • @EPIC_BOI69
    @EPIC_BOI69 Рік тому +6

    Me: verifying that I am not a robot
    Also me: wow these sorting algorithms are the best videos ever!

  • @halicusnguyen8864
    @halicusnguyen8864 3 роки тому +3937

    The most insane thing is that despite having no knowledge of how the heckity heck most of these work I still stay until the end.

    • @ZombieKing05220
      @ZombieKing05220 3 роки тому +32

      literally same

    • @DaemonWorx
      @DaemonWorx 3 роки тому +66

      I'm making sorts myself, that may someday show up in one of these videos and I still don't know how most of these work

    • @itsohaya4096
      @itsohaya4096 3 роки тому +24

      @@DaemonWorx I'm refreshing myself on python specifically to make cool sorting algorithms! So far I've only been able to figure out bubble sort though, and my next goal is shaker sort

    • @theawesome1883
      @theawesome1883 3 роки тому +23

      It's actually pretty simple, here is a vid on how bubble sort works: ua-cam.com/video/xli_FI7CuzA/v-deo.html I am not sure how you would code it tho, or really any thing about data sorting. I am pretty sure that this is just a visual representation of what is going on in code, and correct me if I'm wrong.

    • @soylentgreenb
      @soylentgreenb 3 роки тому +7

      I would say merge sort and insertion sort are the most intuitively obvious. Insertion sort is actually fast at tiny scales even though it seems really dumb.

  • @Glacial7
    @Glacial7 2 роки тому +695

    This gets weirder when you realise that the black part is also being sorted in the exact same way

    • @maggsstuckey487
      @maggsstuckey487 2 роки тому +15

      Do you think that could be a way to store double data? By uaing the black?

    • @kolvis6626
      @kolvis6626 2 роки тому +58

      @@maggsstuckey487 no because the black data is just the inverse of the white data. there's no way to really store different information there.

    • @ruger12
      @ruger12 2 роки тому +8

      @@maggsstuckey487 basically a copy? reflection?

    • @iam2themax352
      @iam2themax352 2 роки тому +16

      Wait they were sorting the white part?

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

      :(

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

    3:52 *takes damage in pikmin*

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

    17:00 this is my favorite one (Bottom-up Merge Sort) SOO satisfying

  • @yatsumura7
    @yatsumura7 3 роки тому +1147

    15:36 There are some methods of sorting that I understand but this one was insane

    • @Ted_II
      @Ted_II 2 роки тому +176

      Sorting speedrun any %

    • @zurps
      @zurps 2 роки тому +183

      From what it looks like it is doing something serious with that auxiliary array rather than modifying the main array.

    • @karolus28
      @karolus28 2 роки тому +105

      @@zurps idk what it means but it sounds right

    • @__-cd9ug
      @__-cd9ug 2 роки тому +149

      looks pretty crazy, I tried to look into it and from what I could understand the first pass that we see is only gathering data which is why it's not changing the positions of anything in that Main Array; instead, it's inputting all the information into the Auxiliary array and the second pass 'reads' that information in a particular way which puts it in order.
      The way it registers the data is that it builds a 'binary tree' which apparently takes the first value as a reference point, then the second value will be either bigger or smaller than the first one, and that determines its 'position' relative to the first one. I've found visual examples on Google, all of which show something that looks more like a root system than a tree (or I guess it looks like an upside down tree) where the first value registered is on top, then the second is below it and to the left if it's smaller, or below it and to the right if it's bigger.
      Then as you keep inputting data it continues to do so, always passing through the whole tree I think. So like if your first value is 50, and your second value is 12 but the third one is 51, then you end up with 50 on top, (that's the root of the tree), 12 below on the left and 51 on the other side, linked to 50. But then if your 4th value is between 12 and 50, then you branch out from 12 and to the right. Every new value branches out from a previous value that doesn't have anything under it.
      The second pass of this system reads the whole tree, starting from the leftmost value, and following the branches of the tree in a specific order. I guess that's a pretty easy task to do for a computer once the tree is built and the reading order is defined, which is why that second pass is so fast.

    • @karolus28
      @karolus28 2 роки тому +22

      @@__-cd9ug cool

  • @peepsiee
    @peepsiee 2 роки тому +1323

    The toilet normally: _quiet, not disturbing at all_
    The toilet at 3AM: 19:40

    • @Tetopettenson1
      @Tetopettenson1 2 роки тому +42

      The goddang toilet is about to drop a nuke from all those crap streaks

    • @grim9040
      @grim9040 2 роки тому +36

      @@Tetopettenson1 thats the worst sentence ive ever heard

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

      X D

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

      @@Tetopettenson1 wha ?

    • @lucylu3342
      @lucylu3342 2 роки тому +7

      @@Tetopettenson1 I am going to sue you for putting "Crap streaks" in my mind.

  • @Secret_Takodachi
    @Secret_Takodachi 9 місяців тому +3

    Comb sort made me chuckle it really was "combing" through that stack to tease out the last little "unsorted" values 😂❤ WTF HOW DID I END UP WATCHING SO MUCH OF THIS! I DON'T EVEN DO ANY SORT OF DATA ANALYTICS OR ALGORITHM CODING?!?!?! Somehow this is just soothing and fascinating to watch ❤👍

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

    It'd be nice for one of these where they're all in the same time base, and same elements... sort them from "least efficient for a significantly random set" vs "most efficient"

  • @OzMediaOfficial
    @OzMediaOfficial 2 роки тому +2962

    I refuse to believe that Shell sort/Gravity sort isnt witchcraft.

  • @eliotdayley518
    @eliotdayley518 3 роки тому +875

    When teach asks the class to line up alphabetically

  • @eventidessoul1963
    @eventidessoul1963 Рік тому +7

    Cycle sort(around 8:05). specifically 8:45, looks like abstract art. The lines represent buildings and they are both in light and dark.

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

    Glad to see an hour this glorious stuff

  • @craycraycat4917
    @craycraycat4917 3 роки тому +747

    imagine this played loudly through a speaker in the middle of a corn field

  • @doghound.
    @doghound. 2 роки тому +1871

    teacher: finishes putting and charging laptops neatly and in correct order before class starts
    the laptops at the end of the class: 5:52

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

      @@acebeingace0002 we used to have that in elementary through 5th/6th grade now we just take the chrome books home

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

      @@acebeingace0002 I'm a respectful guy, I put the Chromebook in the right numbered spot and plug in the charger.

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

      @@spidermonk3uVvwy8-2 I think it’s a normal thing now. At first I thought it was just my school in my area cuz we won a google contest and they came to our school n shit but nah everybody on the wave lol we just didn’t have to pay for it b

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

      Then theres that lazy bum who puts a chromebook on a slot with another chromebook already in it

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

      My dad is a school teacher that had the cart with charging laptops in his classroom, so you already know who he makes to organize them back together at the end of the day everyday 😓

  • @N1ghtR1der666
    @N1ghtR1der666 Рік тому +24

    Winner for when memory is an issue: Shell Sort @4:51
    Winner for when memory is no concern: Counting Sort @21:02

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

    Why did I start watching this video. I’ve never watched anything like it before but, it popped up on my recommended page and I just clicked on it. I’m not saying it’s bad (it’s really satisfying) but, it’s odd for me to randomly click something I’ve never heard of without even being intrigued.

  • @randomdudepersonman2160
    @randomdudepersonman2160 2 роки тому +1726

    "That goth girl is so cute! I wonder what she's listening to."
    What she's listening to: 55:07

    • @lenehammero7274
      @lenehammero7274 2 роки тому +17

      My fave comment so far xD

    • @AngelicMiseryyy
      @AngelicMiseryyy 2 роки тому +31

      🗿

    • @HeelJay
      @HeelJay 2 роки тому +8

      Slow it down. Doesn’t it sound that Family guy scene where the church was trying to find a organist and the kid with the upside down head was playing lmao

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

      Leave these likes at 666 please

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

      This is just 100 gecs

  • @lefishe8303
    @lefishe8303 2 роки тому +342

    This sounds like when I would run my fingers down my dad's comb as a child.

    • @NoOne-bc6sq
      @NoOne-bc6sq 2 роки тому +5

      @Dillon Howington yes everyone did if you didnt growing up, you arent real

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

      IT DOES

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

      i rlly thought you said “dad’s womb”

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

      @@NoOne-bc6sq what about ppl without dads? Are they a figment of our collective imagination?!

    • @NoOne-bc6sq
      @NoOne-bc6sq 2 роки тому

      @@redtoadplush1142 yes

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

    Wow, bottom-up merge sort is so cute and quirky 😍

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

    Best music I’ve ever heard. It’s perfect for studying. Thank you for this amazing study music

  • @Ghost-dq1he
    @Ghost-dq1he 2 роки тому +2899

    The fact that one of the names of the sorts is *"Optimized gnome sort"* is beautiful to me.

    • @NaThingSerious
      @NaThingSerious 2 роки тому +39

      And it’s actually quite efficient

    • @Musicombo
      @Musicombo  2 роки тому +329

      Uuuhhhmmm optimized gnome sort is actually not particularly efficient!!

    • @NaThingSerious
      @NaThingSerious 2 роки тому +25

      @@Musicombo ok, idk much about sorting algorithms but it seemed faster than most of the other sorts (idk if that makes it efficient)

    • @valdonchev7296
      @valdonchev7296 2 роки тому +81

      @@NaThingSerious the speed in this video can be misleading. Two numbers to pay attention to in the top left are the number count (the more numbers sorted in the same time, the better) and the sort time (as opposed to visual time). There's also the question of space efficiency when it comes to using auxilary arrays, but that's a separate issue.

    • @toyotacorolla-dr9ds
      @toyotacorolla-dr9ds 2 роки тому +28

      shoutout tim sort 37:14

  • @destroyerdan6945
    @destroyerdan6945 3 роки тому +482

    19:44 so that's how they made the pac man death sound

    • @XhyRobtic
      @XhyRobtic 2 роки тому +12

      Sounded more like flight of the bumblebees to me lol

    • @abichonfrise-vb6sy
      @abichonfrise-vb6sy 2 роки тому +8

      or is it?
      hey vsauce michael here.

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

    I'm going to make my friends watch this next movie night.

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

    Something about the Bogo Bogo Sort made me feel like I was watching a glitching stereo while another stereo played "In a Gada Da Vida" really faintly in the background. It was also kinda nostalgic which is just strange.

  • @Takapon218
    @Takapon218 2 роки тому +488

    58:19 when you step into an irradiated zone in a video game

    • @nakulab
      @nakulab 2 роки тому +5

      Fallout 3

    • @cheeseman9072
      @cheeseman9072 2 роки тому +10

      Geiger counter moment

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

      @@nakulab stalker....

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

      Minecraft Nether biome ambience

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

      Call of duty 4 Modern warfare's chernobyl mission moment

  • @scottslogic
    @scottslogic 2 роки тому +586

    31:16 so thats where pacman eating got his sound effect

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

    That sound itches some childhood memory but I can't quite nail it down.

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

      maybe some C64 game?

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

    Mesmerizing. Nerd heaven. Awesome visual! Thanks!

  • @TheJudge1933
    @TheJudge1933 2 роки тому +202

    "I'm 13 year old from Atlanta tryin to make outta the hood, these are my best beats"

  • @CrashTherapy
    @CrashTherapy 2 роки тому +4705

    if drugs had a sound they would sound exactly like this

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

    Wow that’s kinda cool I think, reminds me of the sound that makes you go back in time with those cameras

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

    Thremendous work. It would be nice to see the auxiliary array state as well to better understand the algorithms

  • @neino36
    @neino36 3 роки тому +604

    Bogo bogo sort: I WILL FIND EVERY SINGLE POSSIBLE COMBINATION BEFORE I AM SURE! And when I do, I'll invent all other impossible combinations just to see if they fit better!

    • @brandonmathieu1892
      @brandonmathieu1892 3 роки тому +20

      That must be the algorithm that Joshua was using in War Games to find the ICBM launch codes.

    • @zux128
      @zux128 3 роки тому +21

      normal bogo sort: i will try this random combination and check it

    • @KingAm0
      @KingAm0 3 роки тому +15

      Meox_ Seems like it does the same as bogo sort except it will keep going until it checked every combination, even after it finds the right one.

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

      It’s just 6??? It took a solid minute, at least 100 billion combinations to find the fucker that worked

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

      @@meox_ According to the official wiki, it's identical to bogosort except for how it checks whether the list is sorted:
      "To check if the list is sorted, use the following procedure:
      1) Make a copy of the list of numbers.
      2) Sort the first n-1 elements of the copy using bogobogosort.
      3) Check to see if the nth element of the sorted copy is greater than the highest element of the first n-1 elements. If so, the copy is now sorted, else randomise the order of the elements of the copy and go to step 2.
      4) Check to see if the copy is in the same order as the original list. "

  • @K0IBEE
    @K0IBEE 2 роки тому +2732

    i showed this to my dad and i swear he was like “oh thats a binary sort algorithm”
    he then started going off on how the program these and how they work for an hour and i have never been so flabbergasted

    • @Lucian4694
      @Lucian4694 2 роки тому +309

      that’s a good dad, don’t lose it

    • @deanwalker6262
      @deanwalker6262 2 роки тому +167

      Reading this and the comment brings a huge smile to my face. Everything about it, from the dad being cool, to leaving something on here about it, and having Lucian469 comment with those words….it’s fucking fabulous

    • @hollow5683
      @hollow5683 2 роки тому +98

      I’m flabbergasted that you used the word flabbergasted

    • @eduardolindner9333
      @eduardolindner9333 2 роки тому +42

      y'all so wholesome

    • @abandonedaccount123
      @abandonedaccount123 2 роки тому +22

      @@eduardolindner9333 W̷̡̡̡͎̞̤̖͎̘͓͗̉̿̈́̏͘ę̴̢̬̠̭̦̬̬̱̪̺̣̘̅ͅ ̷̡̣̖̬̭̗̹̥̐͛̾̃̋͆͒̓͊̊͘a̴̧̞̦͓̣͋̆͆͗͊͑͘ͅl̶̨͕̫̱͔͉̖͎͈̲̹̺͑̈́̾l̷̹͍̼̥̻̪͓̯̪̠̐͛̀̍̉͒̐̋͆̅̅̕ ̷̢̡̗̰̖͇̳̪͓̺͙̾̐̏̓̈́̌̈́̍̀̏ͅd̶̫̀̆̑̑͑̔͑̅̏̈́̏́͊͑į̶͖̰̙͔͖̳̹̭̱̺͉͈̮̀͗e̶̡͗̐͂̍̎̉ ̵̧̨̛̙̲͖̱̘̦̬̠̝͔͋͊͛̍̆̇̅́͘ê̷̡̛̲͉̝̘̦̟̬̬͈̺͐̉v̴̜̗͒̑͗e̷͖͕̙̺̯̘̠̙̳͒͊̽̋̈́͛̿̈́͗̋͋̆͝ͅn̶̤̭̜̰̭̫͋̃̈́͌̅͑͐͝t̸̞̬͓̜̺̳̬̺̺̖̱͔̚ừ̸̢̻̜͇͍̖̲̝̻͖̞͐̃͊̓̐̅̑͗a̵̙̦͎̗̙̤̗̤̣̾͠ļ̵̢̞͙̖͈̜̰̠̪͔̟͚͊͑l̴̼̻̤͠y̵̧̛̟̣̳̳̗̪̳̝̞̭͉̍͋͜ͅ.̵̧̧̡̧̼͕̻̻̻̟̿̐

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

    i cant stop watching these

  • @Always_a_Duelist
    @Always_a_Duelist 8 місяців тому

    Man, this is the soundtrack to my next session. 👌

  • @megafan523
    @megafan523 3 роки тому +274

    23:40 UA-cam captions: "Music"
    Ah yes, the wonderful ear splitting noise of sorting algorithms

  • @lilbologna8919
    @lilbologna8919 2 роки тому +3558

    As someone with seizures this is very relaxing

    • @aaaaaa-hh8cq
      @aaaaaa-hh8cq 2 роки тому +124

      Hol up

    • @stellasolaria3485
      @stellasolaria3485 2 роки тому +138

      As someone with epilepsy, LSD sort is a certified convulsion moment

    • @jace7g
      @jace7g 2 роки тому +57

      As someone with epilepsy I saw this and said bet

    • @jace7g
      @jace7g 2 роки тому +28

      Yep still good on the not seizing part

    • @vivaleroca7511
      @vivaleroca7511 2 роки тому +37

      Ooh. Seems like you've relaxed on the floor really well. The shaking must be therapeutic. /j

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

    The Flash Sort at 24:42 is really satisfying.

  • @TheNeonLynx
    @TheNeonLynx Рік тому +9

    Some of these seem to be really good as long as you dont need it to be perfect. like let it run through the first 2 or 3 iterations and you have a good approximation. If you need exact sorts they would just be too slow. However I cannot think of many use cases where you want only a rough approximation
    Well I do have a few actually. Imagine writing an NPC for a video game. Throughout the day you want them to certain things and interactions however you do not want them to feel like they are completely scripted. Put their daily routine on a scale from morning to evening. with optional elements. Shuffle sort through 2 iterations. Then let the npc do their tasks based on that list skipping tasks they would not have time for or that are simply not something that npc does every day. However something that sophisticated seems obsolete since in recent years there really has not been much innovation when it comes to video games outside of graphical improvements it seems.

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

      All these have different uses.

  • @alloice642
    @alloice642 3 роки тому +256

    UA-cam: "They will watch anything from this point"

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

      The algorithm:
      Let's just show them what they look like from our side.

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

      69 likes, nice.

  • @DriverNeku
    @DriverNeku 2 роки тому +3085

    FNF players: yo this slaps, when the full week coming out?

    • @inkkda
      @inkkda 2 роки тому +72

      Modders, do your thing. LOL.

    • @Avqoriaa
      @Avqoriaa 2 роки тому +20

      yo this slaps, when the full week coming out?

    • @pepsiman4282
      @pepsiman4282 2 роки тому +13

      I also want a 8192 key song

    • @Migosph
      @Migosph 2 роки тому +7

      @@pepsiman4282 with insta kill notes

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

      @@Migosph and invisible notes

  • @majorse203
    @majorse203 3 місяці тому

    that in-place LSD radix always gets me, no matter what video

  • @greenberrygk
    @greenberrygk 4 місяці тому +1

    I like tournament sort because you can understand how it works from the name alone.

  • @DarkonFullPower
    @DarkonFullPower 2 роки тому +363

    Bogo Sort: "Who are you?"
    Bogo Bogo Sort: "I'm you but worse."

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

      Better*

    • @icarokaue7334
      @icarokaue7334 2 роки тому +16

      BogoBogoBogoSort: BogoBogoSort, but instead of running BogoSort recursively, it runs BogoBogoSort recursively.

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

      What's the difference?

    • @-Danny
      @-Danny 2 роки тому +22

      @@CyberedCake
      Edit: Gavin is correct, I'm overthinking it.
      Bogo Sort: "I will keep randomizing until I find the 1st number. I lock it in place. Then I take everything else and randomize until I find the 2nd number."
      Bogo Bogo Sort: "I will keep randomizing until I find the 1st number. But I swear to God, if I don't land exactly on the 2nd number the next time I randomize, I'm gonna throw it all away and start over."

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

      @@-Danny daaaang

  • @daboohole3551
    @daboohole3551 2 роки тому +1575

    30:40 has to be the most satisfying thing ever

    • @Fireball7428
      @Fireball7428 2 роки тому +19

      In my opinion, LSD Radix looks better.

    • @dustinvanish
      @dustinvanish 2 роки тому +37

      Heard Pacman midway through.

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

      Learning about the metric measurements be like

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

      @@juicymango8400 cuz i live in australia so like it’s normal here 😭

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

      No

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

    I have NO CLUE how i got here. No clue what i’ve watched that relates, but it is oddly satisfying.

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

    Tournament sort is one where you need to see what's happening in the auxiliary array

  • @Blue-jy4rf
    @Blue-jy4rf 3 роки тому +1004

    Mom: "cleaning your room isn't that hard!"
    Cleaning my room: 57:57

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

      @@dawidek4267 no

    • @physchl8658
      @physchl8658 3 роки тому +29

      @@dawidek4267 also how did you come to the conclusion that the joke was being disrespecting about their mother

    • @Nyctomatter
      @Nyctomatter 3 роки тому +17

      @@dawidek4267 when the joke flew over ten miles above your head

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

      @@dawidek4267 yes because she gave me ptsd

    • @Musicombo
      @Musicombo  3 роки тому +38

      @Dawidek That's enough of that. Cool off.

  • @g0tm1lk117
    @g0tm1lk117 3 роки тому +303

    19:32 Galaga enemy decent noise.

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

    Thank you George for introducing me to this wonderful world

  • @memetech-
    @memetech- Рік тому +3

    56:37 HOPE FOR THE BEST