From 16fa336a43a16c9515cdaa8a18276b05f47f3ffe Mon Sep 17 00:00:00 2001 From: Ricardo Islas Ruiz Date: Sun, 25 Feb 2024 14:46:12 -0700 Subject: [PATCH] [go/en]: Clarify comment related to the append function in slices. (#4780) --- go.html.markdown | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/go.html.markdown b/go.html.markdown index d6468f58..0631ffab 100644 --- a/go.html.markdown +++ b/go.html.markdown @@ -130,7 +130,7 @@ can include line breaks.` // Same string type. // Because they are dynamic, slices can be appended to on-demand. // To append elements to a slice, the built-in append() function is used. // First argument is a slice to which we are appending. Commonly, - // the array variable is updated in place, as in example below. + // the slice variable is updated in place, as in example below. s := []int{1, 2, 3} // Result is a slice of length 3. s = append(s, 4, 5, 6) // Added 3 elements. Slice now has length of 6. fmt.Println(s) // Updated slice is now [1 2 3 4 5 6]