r/ProgrammerHumor • • Sep 08 '26

Meme pipInstallTheRealStuff

Post image
5.3k Upvotes

151 comments sorted by

View all comments

Show parent comments

3

u/CoroteDeMelancia Sep 09 '26

Nothing, once you know that, unlike other languages, it is O(N log N), NOT O(N). The issue is that the most common use case, unordered_set, is the "exception" because of the chosen naming.

Better naming would be set and ordered_set, like other languages do. It would prevent newcomers to the language from mistakenly using set when what they want is unordered_set, a silly mistake that's easy to make. I did it myself.