Grammar correction
"it’s possible to pass a capacity explicitly as an additional parameter ot make" "it’s possible to pass a capacity explicitly as an additional parameter **to** make"
This commit is contained in:
parent
1512fb0094
commit
d4af1256f0
@ -20,7 +20,7 @@ func main() {
|
|||||||
// By default a new slice's capacity is equal to its
|
// By default a new slice's capacity is equal to its
|
||||||
// length; if we know the slice is going to grow ahead
|
// length; if we know the slice is going to grow ahead
|
||||||
// of time, it's possible to pass a capacity explicitly
|
// of time, it's possible to pass a capacity explicitly
|
||||||
// as an additional parameter ot `make`.
|
// as an additional parameter to `make`.
|
||||||
s = make([]string, 3)
|
s = make([]string, 3)
|
||||||
fmt.Println("emp:", s, "len:", len(s), "cap:", cap(s))
|
fmt.Println("emp:", s, "len:", len(s), "cap:", cap(s))
|
||||||
|
|
||||||
|
2
public/slices
generated
2
public/slices
generated
@ -95,7 +95,7 @@ the builtin <code>make</code>. Here we make a slice of
|
|||||||
By default a new slice’s capacity is equal to its
|
By default a new slice’s capacity is equal to its
|
||||||
length; if we know the slice is going to grow ahead
|
length; if we know the slice is going to grow ahead
|
||||||
of time, it’s possible to pass a capacity explicitly
|
of time, it’s possible to pass a capacity explicitly
|
||||||
as an additional parameter ot <code>make</code>.</p>
|
as an additional parameter to <code>make</code>.</p>
|
||||||
|
|
||||||
</td>
|
</td>
|
||||||
<td class="code leading">
|
<td class="code leading">
|
||||||
|
Loading…
x
Reference in New Issue
Block a user