Skip to content
Willow 的开发笔记
Go
中间件
DevOps
工具链
前端
AI Agent
Playground
外站链接
CTRL K
GitHub
Light
Dark
System
main.go — Fira Code · Ctrl/Cmd + Enter 运行
Go 1.23.2
Go 1.22.8
package main import ( "fmt" "sync" ) func main() { var wg sync.WaitGroup for i := 1; i <= 3; i++ { wg.Add(1) go func(n int) { defer wg.Done() fmt.Println("worker", n) }(i) } wg.Wait() fmt.Println("done") }
output — go-1.23.2
自动
本地
wandbox
分享
Run
stdin ❯