-
Notifications
You must be signed in to change notification settings - Fork 35
Open
Labels
bugSomething isn't workingSomething isn't working
Description
问题描述
2.2.1,77页
题目四,“答案为D ” 。这个是错的。应该为:“ 答案为C”
如何找到这个错误
- 章节:
- 页码:
您认为应该如何?
图片
如果有可能,尽量提供图片。
其他补充信息
我写了代码进行测试:
package main
import (
"fmt"
"time"
)
func main() {
RangeTimer()
}
func RangeTimer() {
t := time.NewTimer(time.Second)
for _ = range t.C {
fmt.Println("hi")
}
}
输出:
hi
fatal error: all goroutines are asleep - deadlock!
goroutine 1 [chan receive]:
main.RangeTimer()
/Users//go/src/gitee.com/wide288/test/for-range1/main.go:15 +0xcc
main.main()
/Users//go/src/gitee.com/wide288/test/for-range1/main.go:9 +0x25
Metadata
Metadata
Assignees
Labels
bugSomething isn't workingSomething isn't working