Lesson 2 of 4Module 2 · 0% of course
Data Structures & Algorithms · Core algorithms

Sorting & binary search

Why sorting costs O(n log n), how merge sort works, how to sort real data with key functions, and binary search: finding things in O(log n) once data is sorted.

30 min · 6 steps · videoJump to quiz ↓
MIT 6.006 Lecture 3, Insertion Sort and Merge Sort MIT OCW · 30 min
Open in YouTube
Step 1 of 6 · Overview30 min read ·
Key idea
Prereqs: Big-O, Recursion. Next: Heaps & priority queues. MIT 6.006 Lectures 3 & 5.
Next: 1. Sorting in practice
‹ PrevNext ›