I always have to laugh when some gate keeper tries to act like a smart ass. Oh you are so smart but you can't see why they teach a stupid simple algo? Jesus Christ, it's to learn the basics and what not to do.
Why would you teach anyone how not to do something? You know there is many ways to inefficiently sort a list. Why make a video about any of them?
If you're going to teach bubblesort, you might as well teach Bogosort.. maybe eventually after seeing all the ways you're not supposed to sort a list, the student will arrive at a better algorithm on their own. But this seems inefficient. IMO, the introductory algorithm to sorting is Selection sort. It's intuitive and while not terribly efficient, it does allow you to build on the knowledge and introduce more complex algorithms, bubblesort does not.
Bubblesort, is just some stupid peace of trivia that people who are full of themselves like to bring up as a stupidly overused joke.
Why would you teach anyone how not to do something?
Umm. To explain strengths and weaknesses? To explain how to optimize something that already fulfills requirements but isn’t efficient? To make a design trade off that the simpler algorithm is sometimes good enough?
IMO, the introductory algorithm to sorting is Selection sort.
Selection sort introduces state and is therefore way more complicated to explain.
And why do you think it's more complicated to explain? It is literally how a fourth grader would approach sorting a list of numbers, it is how you would sort the money in your wallet, it is the default human way of thinking.
17
u/BruhWhySoSerious Dec 02 '19 edited Dec 02 '19
I always have to laugh when some gate keeper tries to act like a smart ass. Oh you are so smart but you can't see why they teach a stupid simple algo? Jesus Christ, it's to learn the basics and what not to do.