Sign in
go
/
tour
/
23d7fec7297ac454a93338374814f1b4b63f8cff
/
.
/
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")
}