JavaScript's Array.sort() is the embodiment of "task failed successfully." It gives you a sorting method that converts numbers to strings by default (because why wouldn't you?), mutates your original array like it owns the place, and produces the legendary [1, 10, 2, 21] result that's haunted every junior dev's dreams. Then, years of Stack Overflow questions later, JavaScript blessed us with Array.toSorted() - a non-mutating version that fixes exactly ONE of the three problems. You still need to pass a comparator function like (a, b) => a - b to sort numbers properly, and the docs still use that cursed [1, 10, 2, 21] example that looks totally fine until you realize it's lexicographically sorted. The gigachad energy here is JavaScript's unwavering commitment to backwards compatibility - even when the default behavior is objectively wrong for 90% of use cases. Beautiful chaos.