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

19 lines
198 B
Go

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