Algorithms

Complexity analysis

Estimating, without running the code, how an algorithm's time and memory grow as the amount of data grows.

Example

Without testing anything, you know 2 nested loops over 1,000 items do 1 million steps, and over 2,000, 4 million.

Test yourself: Complexity analysis

Measuring efficiency

What's a problem with measuring an algorithm by running it?

Lessons that use it

More algorithms terms

All terms →

Arki, the beaver mascot

Your next interview starts with 5 minutes today.

Free on iOS and Android. Start from zero, no account needed.