Skip to content
Tech Atlas, home
Search
Esc
  • All roadmapsBrowse every learning path
  • ExploreFind a technology area
  • ProjectsGuided projects and builds
  • My AtlasYour learning dashboard
Skill

Sorting Algorithms

Implement and compare the main sorting algorithms and use sorting with key functions as a preprocessing step.

Intermediate1 roadmap

3 objectives 6 steps about 125 min

Check what you know

The lessons are coming later. The knowledge check is ready now.

Take the knowledge check

This skill page is a public outline. Its lessons and knowledge check appear here as subject-matter experts approve them.

Learning objectives

  • Implement insertion sort, merge sort and quicksort with in-place partitioning, and state each one's best and worst time, extra space and stability.
  • Explain the n log n lower bound for comparison sorting and identify inputs where counting or radix sort beats it.
  • Sort records by multiple keys with sorted() and key functions, relying on stability, and recognize problems that become simple once the input is sorted.

Lesson plan

6 steps, about 125 min · 0 of 5 lessons available so far

  1. Insertion Sort and Its Invariant Concept · 15 min · coming later
  2. Merge Sort, Line by Line Worked example · 25 min · coming later
  3. Partitioning: Quicksort and Quickselect Worked example · 25 min · coming later
  4. Beating n log n with Counting and Radix Sort Concept · 20 min · coming later
  5. Lab: Multi-Key Sorts and Sort-First Solutions Lab · 25 min · coming later
  6. Check: Choose and Justify a Sort Knowledge check · 6 questions

Practise it

Implement merge sort and randomized quicksort, verify both against sorted() with randomized tests, benchmark them on random, already-sorted and many-duplicate inputs, and explain the quicksort result on the duplicate-heavy case.

Build it from scratch

Practice builds that exercise this skill by re-creating a real technology.

Browse 1 tutorial that practise it

References

Hard prerequisites

Unlocks

On these roadmaps

Progress and evidence for this skill are shared across all of them.