ThinkChat2.0新版上线,更智能更精彩,支持会话、画图、阅读、搜索等,送10W Token,即刻开启你的AI之旅 广告
> # 并发读不会报错 ~~~ package main import ( "time" ) func main() { m := make(map[int]string) m[0] = "A" for i := 0; i < 100; i++ { go func() { for j := 0; j < 1000; j++ { go func() { _ = m[0] }() } }() } time.Sleep(time.Second * 10) } ~~~