Golang中goroutine线程何时终止问题
/* 程序描述:探索golang中goroutine的用法 */ ```go package main import ( "fmt" "time" ) func saySomething(str string) { for i := 0; i<5; i++ { time.Sleep(time.Millisecond * 1000) fmt.Println(str) } } func m...阅读全文
/* 程序描述:探索golang中goroutine的用法 */ ```go package main import ( "fmt" "time" ) func saySomething(str string) { for i := 0; i<5; i++ { time.Sleep(time.Millisecond * 1000) fmt.Println(str) } } func m...阅读全文