Skip to content

Glossary: Data Structures and Algorithms in Go

Slice

Also written: slices, sub-slice

Go's dynamic array: a window onto an array with a length and a capacity. A sub-slice like `items[a:b]` shares the same array rather than copying it.

Where the book teaches it

Related terms

ArrayCapacityAmortized O(1)