Arrays in Go are fixed-size, value-type containers that store their length as part of the type, while slices are dynamic, reference-type views over an underlying array that store length and capacity separately. Arrays are passed by value and copied entirely on assignment, whereas slices are passed by reference to the underlying data, allowing efficient resizing and sharing. Use arrays when the size is known at compile time and immutable; use slices for dynamic collections.
// Array: fixed size, value type
var arr [3]int = [3]int{1, 2, 3}
// Slice: dynamic size, reference type
var slice []int = []int{1, 2, 3}
// Slicing an array creates a slice
sub := arr[1:3] // sub is a slice, not an array