Skip to content

Glossary: Data Structures and Algorithms in Java

shifting

Also written: shift

Moving items along a list to open or close a gap. Adding or removing at the front of an ArrayList shifts every other item, costing O(n).

Where the book teaches it

Related terms

ArrayListinsertion sort