You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 
 
 

18 lines
266 B

package main
import "time"
func main() {
println("main 1")
go sub()
time.Sleep(1 * time.Millisecond)
println("main 2")
time.Sleep(2 * time.Millisecond)
println("main 3")
}
func sub() {
println("sub 1")
time.Sleep(2 * time.Millisecond)
println("sub 2")
}