golang map

map 的初始化方式 方式一 // Declares a nil map var chapts map[int]string // Initialize map with make function chapts = make(map[int]string) // Add data as key/value pairs chapts[1] = “Beginning Go” chapts[2] = …