Sorting Arrays with NodeJS and Javascript
Sorting algorithms in JavaScript: bubble, merge, quick, and when to pick each one. Commented code plus complexity in practice.
[10, 2, 1].sort() without a comparator sorts as strings → [1, 10, 2]. Knowing bubble, merge, and quick helps in interviews and when profiling sort-heavy code.
What you'll learn: