MCPcopy Create free account
hub / github.com/Swiftie13st/LearningNote / putNum

Function putNum

Golang/Code/basicCode/goroutine.go:191–197  ·  view source on GitHub ↗

func write(ch chan int) { for i := 0; i < 10; i++ { fmt.Println("写入:", i) ch <- i time.Sleep(time.Microsecond * 10) } wg.Done() } func read(ch chan int) { for i := 0; i < 10; i++ { fmt.Println("读取:", <-ch) time.Sleep(time.Microsecond * 10) } wg.Done() } 想intChan中放入 1~ 120000个数

(intChan chan int)

Source from the content-addressed store, hash-verified

source not stored for this graph (policy: none)

Callers 1

mainFunction · 0.70

Calls

no outgoing calls

Tested by

no test coverage detected