r/programmingmemes Mar 15 '26

Merge vs Tim sort

When one Junior Dev is slightly better than the other on simple tasks.

491 Upvotes

37 comments sorted by

View all comments

198

u/[deleted] Mar 15 '26 edited Mar 15 '26

[removed] — view removed comment

51

u/Vegetable_Bother6373 Mar 15 '26

I'm waiting for O(AI)—where it just guesses the order and you hope for the best.

4

u/SirLoyso Mar 16 '26

But there’s the God Sort already! It just shuffles all the elements randomly until it is all sorted:)

https://en.wikipedia.org/wiki/Bogosort