← Back to archive

Stdle #70 · slices · 2026-08-15

What does this Go snippet output?

A past puzzle — fully playable. 4 attempts, hints on wrong guesses.

package main
import "fmt"
func mod(a [3]int) {
a[0] = 99
}
func main() {
a := [3]int{1, 2, 3}
mod(a)
fmt.Println(a[0])
}
Slices
4 attempts left

Answer & explanation