摘要: 申明一个order map的类型: type OrderMap struct { keys []interface{} m map[interface{}]interface{} } keys中按顺序存放map的key 阅读全文
posted @ 2018-03-24 13:58 小蚂蚁_CYJ 阅读(1461) 评论(0) 推荐(0) 编辑
摘要: var b []int = []int{1, 2, 3, 4, 5} fmt.Printf("b[5]= %v \n", b[5]) //发生panic fmt.Printf("b[5:]=%v", b[5:]) //没有panic,打印空切片 阅读全文
posted @ 2018-03-24 09:09 小蚂蚁_CYJ 阅读(149) 评论(0) 推荐(0) 编辑