Skip to content

Glossary: Data Structures and Algorithms in C++

Space

Also written: space cost, extra space

The memory an algorithm needs, which Big-O can describe too. has_duplicate uses O(1) extra space, while a copy of the vector would be O(n).

Where the book teaches it

Related terms

Big-O notation