golang 基础知识4

1.reflect.DeepEqual 深层次判断 map的内容是否都一样

  

m1:=map[string]int{"a":1,"b":2,"c":3};
m2:=map[string]int{"a":1,"c":3,"b":2};

reflect.DeepEqual(m1,m2) //true
posted @ 2018-01-10 17:06  jay-  阅读(72)  评论(0编辑  收藏  举报