What is a concise way to create a 2D slice in Go?
There isn’t a more concise way, what you did is the “right” way; because slices are always one-dimensional but may be composed to construct higher-dimensional objects. See this question for more details: Go: How is two dimensional array’s memory representation. One thing you can simplify on it is to use the for range construct: a … Read more