MCPcopy Create free account
hub / github.com/goinaction/code / printer

Function printer

chapter1/channels/hellochannels.go:10–15  ·  view source on GitHub ↗
(ch chan int)

Source from the content-addressed store, hash-verified

8var wg sync.WaitGroup
9
10func printer(ch chan int) {
11 for i := range ch {
12 fmt.Printf("Received %d ", i)
13 }
14 wg.Done()
15}
16
17// main is the entry point for the program.
18func main() {

Callers 1

mainFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected