slices-underlying-array

command
v0.0.0-...-a2a1f02 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Dec 1, 2020 License: MIT Imports: 1 Imported by: 0

README

slices-underlying-array example

A slice being appended to showing the underlying array being added to the slice.

GitHub Webpage

LENGTH AND CAPACITY OF A SLICE

Slices are build on arrays,

  • The length of the slice is just the length of the slice.
  • The capacity shows what the underlying fixed length array is being used.

This example demonstrates this by appending to a slice and showing how the underlying array changes (the capacity).

RUN

go run slices-underlying-array.go

Documentation

The Go Gopher

There is no documentation for this package.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL