> For the complete documentation index, see [llms.txt](https://minilabmemo.gitbook.io/golang-memo/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://minilabmemo.gitbook.io/golang-memo/basic/wen-ti.md).

# 問題

問題

[Go的50坑：新Golang开发者要注意的陷阱、技巧和常见错误\[1\]](https://zhuanlan.zhihu.com/p/141878854)

```go
func main() {
	var a map[string]int
	a["a"] = 1 //panic: assignment to entry in nil map
	b := a["b"]
	print(b)
	if b != nil {// compile- invalid operation: v != nil (mismatched types int and untyped nil)
		print(v)
	}

}
```
