Suppose this is my sample code. On running it outputs [[]][[] []][[] [] []][[] [] [] []]
. Help me in understanding what this code is depicting and what is routingtable [][]*node called in programming terminology. Is it a slice of slice of node or is it a 2d array of node type. Forgive me if I sound dumb but I am just trying to learn.
package main
import "fmt"
type node struct {
id int
}
func main() {
var routingtable [][]*node
for i := 0; i < 4; i++ {
routingtable = append(routingtable, []*node{})
fmt.Print(routingtable)
}
}