package main
import "fmt"
func main() {
a := [][]int{
{4, 2, -9},
{11, 8, 60},
}
fmt.Println(a)
for i, row := range a {
fmt.Println("Row ", i)
fmt.Println("\t", row)
for j, v := range row {
fmt.Println("j:", j, ", v:", v)
}
}
}
Output
[[4 2 -9] [11 8 60]]
Row 0
[4 2 -9]
j: 0 , v: 4
j: 1 , v: 2
j: 2 , v: -9
Row 1
[11 8 60]
j: 0 , v: 11
j: 1 , v: 8
j: 2 , v: 60