box-o-sand/oldstuff/gotime/gotour-artifacts/goroutines/main.go
2015-06-22 13:15:42 -05:00

19 lines
195 B
Go

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")
}