- http://divan.github.io/posts/go_concurrency_visualize/
- https://codeburst.io/why-goroutines-are-not-lightweight-threads-7c460c1f155f
- https://golangbot.com/channels/
- https://golangbot.com/goroutines/
- http://container-solutions.com/surprise-golang-thread-scheduling/
- Defer, Panic and Recover: https://blog.golang.org/defer-panic-and-recover
for k, v := range m {
fmt.Printf("key[%s] value[%s]\n", k, v)
}
or
for k := range m {
fmt.Printf("key[%s] value[%s]\n", k, m[k])
}
m := make(map[int]bool)
To get the data from map
m[121]
Creation:
list.New()
Accessing element from the list:
type Node struct {
row int
col int
}
for e := l.Front(); e != nil; e = e.Next() {
row := e.Value.(*Node).row
col := e.Value.(*Node).col
}