JavaScript · Senior · Question 75 of 75

Is Array.prototype.sort stable in modern engines?

Explanation

Stability enables multi-key sorting: sort by name, then by department, and people within a department stay alphabetical.

Further reading

Problem with a question

JavaScript · Senior · question 75

Test yourself

Take the JavaScript · Senior quiz: questions and options are shuffled, and you get a review of your mistakes at the end.

Take this quiz