Skip to content

Glossary: Data Structures and Algorithms in C++

Amortized

Also written: amortized O(1)

Cost averaged over many operations. A vector's push_back is occasionally slow when it must move everything to a bigger block, but it averages out to O(1).

Where the book teaches it

Related terms

Dynamic arrayBig-O notation