github.com/brownsys/tracing-framework-go@v0.0.0-20161210174012-0542a62412fe/go/darwin_amd64/misc/tour/content/concurrency/goroutines.go (about) 1 // +build OMIT 2 3 package main 4 5 import ( 6 "fmt" 7 "time" 8 ) 9 10 func say(s string) { 11 for i := 0; i < 5; i++ { 12 time.Sleep(100 * time.Millisecond) 13 fmt.Println(s) 14 } 15 } 16 17 func main() { 18 go say("world") 19 say("hello") 20 }