Skip to content

Glossary: Data Structures and Algorithms in C++

Shifting

Also written: shift, shifts

Moving items along a list to open or close a gap. Inserting or erasing at the front of a vector shifts every other item, which costs O(n).

Where the book teaches it

Related terms

Dynamic arrayInsertion sort