When looping through an array, the first variable returned is the index, and the second variable returned is the value:
array := []int{2, 3, 4}
for index, value := range array {
fmt.Printf("Index: %s, Value: %s
", index, value)
}
What is returned when looping through map with the range clause. It is not the same as for array. There cannot be an index of a map anyway. Can we get key names?