Glossary: Data Structures and Algorithms in Go
Shifting
Also written: shift, shifts
Moving items along a slice to open or close a gap. Inserting or deleting at the front shifts every other item, which is why it costs O(n).
Glossary: Data Structures and Algorithms in Go
Also written: shift, shifts
Moving items along a slice to open or close a gap. Inserting or deleting at the front shifts every other item, which is why it costs O(n).