Go by Example Check out the first example or browse the full list below Unless stated otherwise, examples here assume the latest major release Go and may use new language features
: Maps - Go by Example : Maps Note that maps appear in the form map[k:v k:v] when printed with fmt Println $ go run maps go map: map[k1:7 k2:13] v1: 7 v3: 0 len: 2 map: map[k1:7] map: map[] prs: false map: map[bar:2 foo:1] n == n2