提交 20eb8022 编写于 作者: 麻凡_'s avatar 麻凡_

fix:修改 helloword 错误

上级 880cdad6
......@@ -3,25 +3,26 @@
```Go
func main() {
s := []int{1, 2, 3} // len=3, cap=3
s := []int{1, 2, 3}
a := s
s[0] = 888
s = append(s, 4)
fmt.Println(a, len(a), cap(a)) // 输出:[888 2 3] 3 3
fmt.Println(a, len(a), cap(a))
fmt.Println(s, len(s), cap(s)) // 输出:[888 2 3 4] 4 6
}
```
## 答案
`[1 2 3] 3 3``[1 2 3 4] 4 6`
`[888 2 3] 3 3``[888 2 3 4] 4 6`
## 选项
### A
`[888 2 3] 3 3``[888 2 3 4] 4 6`
`[1 2 3] 3 3``[1 2 3 4] 4 6`
### B
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册