1
0
gotour-notes/concurrency/hello/go.go

19 lines
198 B
Go
Raw Normal View History

2012-09-03 07:37:10 -07:00
package main
import (
"fmt"
"time"
)
func say(s string) {
for i := 0; i < 5; i++ {
time.Sleep(time.Millisecond * 100)
fmt.Print(s)
}
}
func main() {
go say("world!!\n")
say("hello ")
}