Skip to content

Glossary: Go Basics

Map

Also written: maps, key-value pairs, key

A collection of key-value pairs where you look up a value by its key, like SKU to stock count. Iteration order is random, and `v, ok := m[k]` tells you whether a key exists.

Where the book teaches it

Related terms

nil map