别的不说,直接上代码
user:=make(map[string]string)user["wang"]="王"if user["wang"]!=""{ print("存在")}if _,ok:=user["wang"];ok{ print("存在")}
应该就是key的内存的直接或者间接的比较