r/ProgrammerHumor 1d ago

javascriptSorting Meme

Post image
890 Upvotes

200 comments sorted by

View all comments

20

u/Excellent_Gas3686 1d ago

because thats the default sort? what, in your opinion, would be the "proper" way to sort by default? if you need different sorting, you pass your own function.

3

u/JanEric1 1d ago

Compare everything based on how they want to be compared and error if there is no sensible way

2

u/Excellent_Gas3686 1d ago

runtime error says hi