Visualizations: kzitem.info/news/bejne/tqdsu4awqGuiaZw I hope you enjoyed learning about algorithms! And for returning viewers, I hope you enjoy the trip down memory lane!
@Johnny_Franco-12_Scratch
4 ай бұрын
こんにちは、クヴィナ・サイダキ!
@CaptainDangeax
4 ай бұрын
Great vidéo. I'm gonna play with my C128 ASM just for the fun of it, trying to implement some of them and programming the VDP
@truongquangduylop33yyuh34
3 ай бұрын
did musicombo wat ch this video
@truongquangduylop33yyuh34
3 ай бұрын
I Optimized Porportion Extend Sort with this: Sorting ¼ of the list then choose the median. (FOR UNDER 32 ELEMENTS ONLY).
@Patricia_Taxxon
4 ай бұрын
genuinely love the way you've adapted this into a worlthwhile viewing experience rather than just a compilation, the little titles are so cute, and the new bits of voiceover make this feel like it was always supposed to be one huge video.
@M113sAldrich
3 ай бұрын
I was going to make that Adam Sandler joke but I understand why you are here
@Patricia_Taxxon
4 ай бұрын
kuvina i am rooting for you
@jan_Eten
4 ай бұрын
mood also omg is ðat patricia taxxon ( 'o') i loved your love rap explanation in rhythm heaven iceberg megamix ( ^u^)b
@MarkusIfquil
4 ай бұрын
patricia ily
@RadioactiveBluePlatypus
4 ай бұрын
Omg hii you're my favorite autistic furry youtuber yippee! /genuine Helped me realize I'm autistic myself
@temmie1662
4 ай бұрын
@@RadioactiveBluePlatypusoh oh hi /gen
@paper2222
4 ай бұрын
our favorite enby buddy
@maadneet
4 ай бұрын
Have I watched each of the individual videos before? Yes. Will I watch this compilation? Absolutely.
@wyattstevens8574
4 ай бұрын
There's also a visualization-only companion!
@maadneet
4 ай бұрын
@@wyattstevens8574 Watched that too!
@TessaLucy
4 ай бұрын
The idea of sorting networks is really reminding me of how factorio balancers work
@robertmauck4975
4 ай бұрын
That was my first thought too
@octopodes_nuts
3 ай бұрын
I would not be surprised if there's Factorio builds that contain otherwise-unknown algorithms that beat any documented method, whether sorting or some other interesting task
@MonitorLizardGaming
4 ай бұрын
Two hours of high quality and well-thought-out content? Am I dreaming??
@yellowmarkers
4 ай бұрын
There goes my plan to make a sorting algorithm explanation. I can just redirect people here now.
@EntergeticalakaBot
4 ай бұрын
There goes the ideas, being used by others
@realmless4193
4 ай бұрын
Just checked out your channel because of this comment. Did subscribe.
@mistymysticsailboat
4 ай бұрын
does anyone else ever get annoyed at Quick Sort being called Quick Sort, like that just feels unfair to the rest of the sorts. why isnt it called like "Partition Sort" or something
@mistymysticsailboat
4 ай бұрын
and like it Clearly has weaknesses. it is horrible on an already sorted list.
@Kettwiesel25
4 ай бұрын
Pivot sort is more descriptive I think
@pangpanggao
3 ай бұрын
I think it is due to the fact that it is one of the fastest algorithms known, so they just called it quick sort and got it done with.
@HA11EYS_COM3T
2 ай бұрын
Rectangle sort because the sub-lists are rectangular
@NostraDavid2
Ай бұрын
You'll have to look at computer history to get an answer. Long story short Tony Hoare (pronounced "hor" - he's British) invented it because his insertion sort implementation wasn't fast enough for some software he created. And it was quite a bit faster than insertion sort, hence the name. And the rest is history. Edit: this was back in 1959, which is an important detail, since not all will known sort algorithms were yet invented.
@ManicVolcanic
4 ай бұрын
Very nice video. Regarding the bonus section at the end -- you'll no doubt be pleased to hear that the latest SIGBOVIK conference introduced bogoceptionsort! Bogosort may accidentally sort very small lists correctly in only a few iterations. To prevent this, bogoceptionsort first shuffles the *order of the lines of code* that make up the bogosort implementation, then attempts to run it, then checks to see if the list is sorted. This effectively pads the number of elements in the list, making it perform extremely poorly for even lists of size, like, five.
@edgeman1135
3 ай бұрын
A cool optimisation would be to calculate the chance to order the lines correctly, and to reject a correct solution with that probability. Hope this helps to sort your 5 items in less time!
@ultra824
4 ай бұрын
Here's a favorite joke algorithm of mine: Intelligent Design sort. It works like this: First, observe that the probability of the array being in the exact order that it's in by chance is 1/(n!), this is so unlikely that we must conclude that the array was put in that order by an intelligent Sorter, who must have sorted the elements by some metric beyond our mortal comprehension. This means that any change we might make to the array would actually make it _less_ sorted, which would be against the Sorter's plan. Therefore, the algorithm is complete. This has O(1) Time Complexity.
@evanzieg
4 ай бұрын
I'm a huge fan of all of the icons! They are all very clean and well designed! Great work on all the visuals and research in the series!!
@Musicombo
4 ай бұрын
Once again, your explanation for Grailsort makes me smile ❤
@bitonic589
21 күн бұрын
Musicombo
@migueltorrinhapereira7473
4 ай бұрын
This series of videos inspired me to create a sorting algorithms visualization that runs on my CASIO graphical calculator, I implemented 16 different algorithms and it was really fun. Thank you. Great video, very helpful and interesting.
@colly6022
4 ай бұрын
bubble sort and shaker sort are definitely the most intuitive for me, as i've unknowingly been doing smth very similar my whole life for real-world situations!
@HesterClapp
4 ай бұрын
I think insertion sort is more intuitive than bubble sort. Bubble is easier to code, but it's harder to convince yourself that it works
@not_estains
4 ай бұрын
i use radix lsd base 2 sort irl
@FinnPlanetballs
4 ай бұрын
20:38 there is an among us hidden in the purple bar
@jan_Eten
4 ай бұрын
yeah i know
@wyattstevens8574
4 ай бұрын
Didn't notice that!
@theunknown4834
4 ай бұрын
Really something among us
@Spax_
4 ай бұрын
went looking for this comment
@krabman6297
4 ай бұрын
Someone should make a paranoid sort algorithm, like bubble sort, but it swaps items a random amount of times just to make sure it's actually swapped, and should have a save function it spams just in case it crashes. You can also make it randomly mess up or starts over completely, maybe even go through twice and compare the two finished sorts to see if it got the same outcome before determining if it's sorted or not
@feelshowdy
Ай бұрын
Brilliant.
@epikoof
4 ай бұрын
gotta admit, 80% of block sort flew over my head after sqrt, but i loved this entire video anyway, thank you so much
@SysFan808
4 ай бұрын
sorting algorithm i made (and probably many others too) so, i started with bogo, but then tweaked the randomiser function. it was originally picking 2 random values and swapping them i changed that "swapping" to "comparing" them. i don't know what to call it, but it does work quite well as a sorting algorithm.
@antoninduda9078
4 ай бұрын
I think it's called either bubble bogo sort or exchange bogo sort
@wiktorszymczak4760
4 ай бұрын
Forever proud of actually using bogosort back in uni and getting it accepted
@m_affiliates
3 ай бұрын
Please elaborate
@HA11EYS_COM3T
Ай бұрын
I need the story. Please.
@augie279
4 ай бұрын
I don’t understand any of how block sort works but I’m glad computers do
@pangpanggao
2 ай бұрын
Tbh you really don’t need to care about space complexity TOO much, because if you count the memory needed to store the original array, all algorithms in this video would become O(n) space complexity, thus merge sort is good enough
@mithrilbookofmystery
4 ай бұрын
genuinely I love this so much. I do not know enough math to keep up with your descriptions 100% of the way, but what I can parse is genuinely very interesting. I love sorting algorithms, and I love learning more about how they work, even if I can never fully understand it. Thank you so much for this video! I was enraptured all the way through.
@mithrilbookofmystery
4 ай бұрын
Ahhh I lied I was actually still watching - near the beginning - when I wrote this but by god I am still enraptured. I'm going to start commenting on the little things I'm enjoying as I go along, because there are many, and I couldn't stop myself at just the one comment. First of all: I love your explanation of the use cases for these algorithms. Or, well, I'm currently just in merge sort, I'm unsure if you keep doing it down the line, but still! it's cool to know the pros and cons of each sort, and why one algorithm would be used over another, as in your city name sorting example.
@mithrilbookofmystery
4 ай бұрын
20:38 >:0!!!!!
@RT777
3 ай бұрын
Stumbled across this awesome video and liked it 5 minutes in. It’s great, but I would suggest adding a touch more emotion in to it. Great video!
@t1maggedon
5 күн бұрын
I cannot believe the amount of work and attention to detail plus the succinct, concise, and sensible quick-tutorial on asymptotic notations. In fact, I happen to be learning about it in grad-level CS algo class rn. Your video has helped me immensely and in total contrast to the quest for faster algorithm, I hope your channel grows in astronomical Big O! ❤
@mrtopper930
4 ай бұрын
I’m learning math and science for college majors at 10:30pm. I fell proud.
@HA11EYS_COM3T
Ай бұрын
I don’t even know how many times I’ve rewatched this video by now
@joelicandi2586
4 ай бұрын
Fantastic Work !! very impressive
@Skyb0rg
4 ай бұрын
1:52:30 Quantum bogosort is actually implementable, but would be O(2^n) in all cases, since you need to spend time creating those 2^n “worlds” to destruct. There is another interesting sorting algorithm, which is the “differentiable sorting” algorithm. It takes in a list and returns the permutation required to make it sorted, but the entire algorithm can be differentiated (needed in ML and for incremental computation).
@MichaelDarrow-tr1mn
4 ай бұрын
actually o(n!)
@cowcat8124
2 ай бұрын
One flaw with Quantum Bogo Sort is that you can't use a traditional RNG function because they're deterministic. You have to use an RNG function that is dependent on true randomness
@skittlez0496
4 ай бұрын
A variation on quantum bogo sort (without the universe destruction): Step 1) go through the entire list to see if it’s sorted, also counting what n is in the process Step 2) with n! parallel processors and n! auxiliary arrays, distribute each element evenly into each open spot in each array, which guarantees that each array is distinct* Step 3) because each auxiliary array is necessarily distinct, and we have n! number of them, exactly one must be sorted. Simply use all our parallel processors to comb through them simultaneously to find the sorted list. Boom, the fasted on average sorting algorithm possible (time complexity of n) The only issue would be the space and processing it requires…
@skittlez0496
4 ай бұрын
*if the list doesn’t contain strictly distinct values, there will be multiple auxiliary arrays which are sorted, but still only one that is sorted stably We can make this algorithm stable by taking the first auxiliary array (which is necessarily just a copy of the original list) and use it as a “stable” memory storage to help find the one true stably sorted list
@etaosin
3 ай бұрын
Great work, congratulation. Certainly watch one time is not enough. But understanding level again increased in my situation.
@lerq0ux
4 ай бұрын
I came looking for one of those “every __ explained” videos but i got something much better
@ERRORRubiksZeraBrand
4 ай бұрын
i am trying to make a sorting visualizer in python by using your terminal and using pygame for the sounds. i didn't understand many sorting algorithms but this helped me understand some of the algorithms. i also included one of your sorting algorithms (baiai sort) inside. thank you for the explanation and peace.
@matt.w
7 күн бұрын
I once needed to sort a list, but didn't knew any sorting algorythms, so I accidentally wrote bubble sort.
@epikoof
4 ай бұрын
kuvina, patricia taxxon and jan misali should all collaborate sometime
@Manabender
15 күн бұрын
Holy crap. I've been studying computers for years, and always had a soft spot for quicksort, and yet, this is the first I've ever seen the sort-in-place strategy you detailed. I always thought each round would require copying all elements less than the pivot to a new list, and all elements greater to another new list, essentially requiring O(nlogn) memory.
@ceremyjlarkson9475
4 ай бұрын
20:38 Quite suspicious indeed
@rainbowwdude
4 ай бұрын
How much sorting algorithm do you want? Me: *_Yes_*
@WebMafia
2 ай бұрын
i haven't watched the video fully yet, but what amazed me now is the in-place implementation of Quicksort. I'd usually make auxiliary arrays around the pivot point, write the compared values there and then sort the auxiliary arrays.
@ishu4227
3 ай бұрын
49:56 this feels so much like a meme template and i love it
@feelshowdy
Ай бұрын
Thank you so much for this in-depth video. My only knowledge/exposure to sorting algorithms before this were those meme videos where sorting algorithms make funny sounds. Now I have come away confused yet mystified, and with favorite sorting algorithms being Pancake Sort and Power Sort.
@kaderen8461
4 ай бұрын
i will not need this information. but it begs to be watched
@ryanbartlett672
4 ай бұрын
Great work. Thanks
@fuschia-draws
4 ай бұрын
each algorithm has a little icon !? very cute i love it
@thumbgoblin4716
4 ай бұрын
ive already seen all 4 videos, is there anything new in this one?
@Kuvina
4 ай бұрын
not really I just redid some audio and visuals to make it easier to watch, and added segues between the sections
@jursamaj
4 ай бұрын
22:10 I may have mentioned this in the original video, but radix sort *can* be used on strings (as long as characters have a fixed-size representation). It's most efficient with fixed-size strings, but can even be used on variable length strings.
@kitsuneprincess4637
2 ай бұрын
I'm so glad you included my favorite sorting algorithm, miracle sort!
@arcainchaos
4 ай бұрын
I am less than a minute into the video and I need you to know that I love you
@DavidvanDeijk
4 ай бұрын
very enjoyable, thank you. shell sort is indeed a favorite.
@namethathasntbeentakenyetm3682
4 ай бұрын
Now I can understand the things
@12times12_
4 ай бұрын
bitonic sort visualizes the swaps that are needed to make a belt balancer in the video game Factorio lol
@tobyconner5827
4 ай бұрын
you should do a longer video about joke algorithms (especially more obscure ones like hanoi sort), theyre very fun
@Musicombo
4 ай бұрын
Hey, just to letcha know: you are more than welcome to join The Studio so you can stay updated on Holy Grailsort's progress (once we come out of hiatus, which is hopefully soon)! ❤❤
@bitonic589
21 күн бұрын
Idk if this would make it faster, but you could try picking the first and last element and move them inwards, swapping elements that are out of order That would reverse a descending array and insertion sort would finish the sort, and it would also get rid of lots of patterns
@Musicombo
21 күн бұрын
@bitonic589 That would break stability, unfortunately, but it's still a clever idea! You would have to implement it like Timsort does, but block merge sorts don't work off of pre-existing runs of sorted data.
@mitchellbailey5522
4 ай бұрын
Honestly quite incredible
@ShowMe7.
4 ай бұрын
yay new kuvina video :3
@proton..
4 ай бұрын
as pictures
@Living_Murphys_Law
4 ай бұрын
as pictures
@CompilerHack
4 ай бұрын
you make the best videos!
@stefanbergung5514
4 ай бұрын
Wasn't there an algorithm that can solve any NP-problem in its minimal time complexity by random generating algorithms and checking if there answer is correct? It's just generliced bogo-sort, but would have been worth a mention.
@mommyuki
4 ай бұрын
new Kuvina video! I already love it
@TheBalthassar
4 ай бұрын
I'm pretty sure I said this on the original video, but when we got to the sorting networks and bitonic, my mind goes to Factorio belt management theory.
@sunanimatons
3 ай бұрын
I have a good joke sorting algorithm, Increment sort, so basically, it compares adjacent pieces right to left, like reverse bubble sort, but if the left is greater or equal to the righ, decrement left by 1 and increment right by 1, not reccomened for few unique values.
@ShaAngFox
2 ай бұрын
I think I came up with a new sorting algorithm The way it works is by comparing the the farthest left two pieces and if they are not correctly sorted it deletes both of them and then moves one to the right then repeats until it is sorted
@mxsteri0
Ай бұрын
but don't you lose data from doing so?
@A_literal_cube
7 күн бұрын
This is similar to stalin sort
@RT777
3 ай бұрын
Minor typo - 1:05:15 says O(nlgon) instead of O(nlogn) in the magenta rectangle
@sunanimatons
3 ай бұрын
Baiai sort can also be called Odd Even Insertion(because it’s also “odd even”ish.
@vincehomoki1612
4 ай бұрын
1:05:13 Typo! "and building it is O(nlgon)"
@Kuvina
4 ай бұрын
I'm impressed by how many people have noticed that. But I guess it shows people are really paying attention to the video!
@Inspirator_AG112
3 ай бұрын
*@[**37:04**]:* This is also the same algorithm used by Earthbound.
@LexiLex421
Ай бұрын
Why does nobody get rid of the parts like “the rest are in part 2!”
@LeoStaley
4 ай бұрын
Are there different considerations based on properties of the data, like numerous peices of data with the same values? In such a data set is there anything of note happening when a secondary sort method is used? (Like sorting files by album title, and secondarily by name, or track number? What about if the data is already partly sorted instead of random?
@Kuvina
4 ай бұрын
That's where adaptive algorithms come in, which are covered in part 3 !
@NXTangl
4 ай бұрын
For "A-then-B" you can just sort by A but break ties by B, or you can sort by B, then stable sort by A, or you can use a recursive procedure more like MSD radix sort.
@LeoStaley
4 ай бұрын
@@NXTangl does anybody know how windows explorer does it?
@NXTangl
4 ай бұрын
@@LeoStaley Probably stable sort.
@MikeBud-ju9ks
Ай бұрын
29:22. Is it a mistake, that there's 3 instead of 4 or is it just a joke?
@AshLikes2analyse
4 ай бұрын
You're the best
@HesterClapp
4 ай бұрын
I think I saw somewhere that the time complexity of Shell sort is O(n (log n)^2), which is roughly n^1.2, but I couldn't tell you why that's the time complexity
@Kettwiesel25
4 ай бұрын
O(n log^2 n) is a smaller time complexity than n^1.2 or even n^1.00001
@fwuz_
3 ай бұрын
pairwise bogo sorting network: given a list X of size n, generate a new list P containing all ascending pairs of integers from 0 to n-1. shuffle P and use it to compare every pair of numbers in X, swapping them if necessary. if X isn't sorted throw your computer in the ocean or something idk
@fwuz_
3 ай бұрын
update: i made it and it's every bit as horrible as i had hoped
@typo691
Ай бұрын
Was hoping to see an explanation of shatter sort 😢 There are basically no explanations of it online
@noahnaugler7611
2 ай бұрын
do you really need a temp variable to swap values? I thought { a=1; b=2; a=a+b; b=a-b; a=a-b; } now a=2, b=1
@Kuvina
2 ай бұрын
That's a cool method! Although I think it only works on numbers and has a negligible effect on performance, so usually we just stick with the general method.
@mathguy37
4 ай бұрын
cool now i can watch this when binging it the 581st time
@ashes6816
4 ай бұрын
this is so good
@cxpKSip
3 ай бұрын
Radix Sort could work on any set of finite elements.
@Inspirator_AG112
2 ай бұрын
*@[**1:52:40**]:* I guess it isn't literally named after a real-world genocide perpetrator for nothing... Go figure with how destructive it is.
@circuitcraft2399
4 ай бұрын
1. Quicksort can include smarter pivot-selection techniques to guarantee O(n*log(n)) time in the worst case. 2. Shellsort can be O(n*log(n)^2) if you choose the sequence of gaps more carefully. Additional details in replies.
@circuitcraft2399
4 ай бұрын
Explanation for 1: there is an algorithm called "median of medians." It is an O(n) algorithm that finds some value in the list that is greater than (or equal to) at least 30% of the others in the list, and also less than (or equal to) another 30% of them. By using it to choose pivots, we will always shrink the list by a constant factor on each step, guaranteeing logarithmically-many recursive steps.
@circuitcraft2399
4 ай бұрын
Explanation for 2: if we choose the sequence of 3-smooth numbers, we never swap an element more than once on a given iteration. Since there are O(log(n)^2) 3-smooth numbers less than n, we perform that many linear-time iterations.
@Vaaaaadim
4 ай бұрын
I'm only at the start of the video right now, but I just want to note that ska sort doesn't seem to be included.
@kisho2679
3 ай бұрын
which one is most used in practice?
@not_estains
4 ай бұрын
now explain every shuffling algorithm
@taureon_
4 ай бұрын
identity crisis sort should randomly start off with quick or merge
@HalfEye79
3 ай бұрын
You can improve gnome sort, when use put the index in a variable you turned back into a variable. When the piece is at is correct destination you can just go to the saved index.
@77elite9
2 ай бұрын
At that point that’s insertion sort and you might as well use that instead.
@rhnirsilva652
3 ай бұрын
this is fucking cinema
@eastonbrunet9996
23 күн бұрын
57:51 I can't believe Americans are calling it *Zed* instead of *Zee* 💀
@Buckybadgerwisco
22 күн бұрын
I can’t believe either, you are talking British style for *Z*
@BoBoN4Uto
4 ай бұрын
marvel moieverse been real quiet since this dropped
@andriypredmyrskyy7791
4 ай бұрын
Fun fact, Bill Gates published a really neat paper on pancake sort! I wish I was smart enough to understand it. I'd watch a video of someone explaining that paper online.
@BFUS_official
4 ай бұрын
I keep hearing login
@MessyMasyn
4 ай бұрын
Can't wait to get hired at Google/Facebook/Papa Johns
@WendidIask
4 ай бұрын
Top sort is not obscure :(. It is used in every DAG problem basically.
@trapit1v145
Ай бұрын
Me at 12AM: 4:59 "...Yeah."
@mxsteri0
Ай бұрын
yes.
@wilamifce
3 ай бұрын
Whatt is a pivot???????????????
@truongquangduylop33yyuh34
2 ай бұрын
1:13:40 Like CycleSort's cycling method 😮
@truongquangduylop33yyuh34
2 ай бұрын
Here is my case 3 for block sort: There is no g.
@77elite9
2 ай бұрын
It explicitly stated, “if necessary, introduce gap g so A and B have no common values.” If A and B had no common values to begin with, there’s no need to introduce gap g in the first place.
@RadioactiveBluePlatypus
Ай бұрын
When I learnt about insertion sort I came up with binary sort lol
@not_estains
4 ай бұрын
radix sort is so cool
@FerPerez-mc3wr
2 ай бұрын
What if the moon is made of cheese?
@eskaigarcia
3 ай бұрын
Wow, just wow
@junebugrobotics
3 ай бұрын
It's 117 minutes and 33 seconds! How dare you lie!
Пікірлер: 215