Sign in
go
/
tour
/
6bb846ce41cdca087b14c8e3560a679691c424b6
/
.
/
content
/
concurrency
/
goroutines.go
blob: 9efc83348e65048ee44141282fd297a0e537b361 [
file
] [
log
] [
blame
]
// +build OMIT
package main
import (
"fmt"
"time"
)
func say(s string) {
for i := 0; i < 5; i++ {
time.Sleep(100 * time.Millisecond)
fmt.Println(s)
}
}
func main() {
go say("world")
say("hello")
}