package main import "fmt" func main() { // 直接初始化创建 m := make( map[string]string ) // 赋值 m["site"] = "aiezu.com" m["name"] = "爱E族" m["test"] = "123456" // for 输出 for key, val := range m { fmt.Print(key, "\t", val, "\n") } }