NeetCode on YouTube · Open on YouTube
Foundations: programming and problem solving · Novice · Lesson 11 of 98 · 21 min video, then about 4 hours of practice
Big-O: reasoning about how code scales
After this you can state the time complexity of simple loops and lookups and recognise when nested loops will be too slow.
Why it matters
Big-O is a vocabulary for one practical question: if the input gets ten times bigger, how much slower does this get? You need it to spot code that works on ten items and falls over on a million, and you will be asked about it in interviews. Learn the common classes (constant, logarithmic, linear, n log n, quadratic) and practise identifying them in your own exercise solutions. Notice that a lookup in a `Map` is constant time while `array.includes` is linear; that one fact fixes a large share of real performance bugs. Trap: obsessing over constant factors or micro-optimisations. Big-O is about the shape of growth.
How to use this resource
Clear, practical, and aimed at exactly the level you need.