Big-O growth explorer
Compare how common operation-count models grow as input size changes.
Compare abstract growth with a coefficient of one. This is not a benchmark or an automatic analysis of pasted code. The logarithmic model has a minimum of one operation for display.
| Model | Units of work | Example |
|---|---|---|
| O(1) | 1 | Read an array slot |
| O(log n) | 6.64 | Binary search |
| O(n) | 100 | Scan every record |
| O(n log n) | 664.39 | Typical comparison sort |
| O(n²) | 10,000 | Compare every pair |
Bars use a logarithmic scale so small values remain visible. Constants, input distribution, memory use and hardware affect real performance.
Turn the result into understanding
Increase the input by a factor of ten. Compare linear and quadratic growth. Then identify which operation repeats in your own algorithm; counting only the number of visible loops can miss work performed inside a function call.
Reference: Official documentation