1
0
mirror of https://github.com/vlang/v.git synced 2023-08-10 21:13:21 +03:00

doc: fix example program for array (#5926)

This commit is contained in:
Koki Nishihara 2020-07-22 23:28:09 +09:00 committed by GitHub
parent 0f72328d1f
commit 44c280e522
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -497,7 +497,7 @@ Setting the capacity improves performance of insertions, as it reduces the amoun
dynamic arrays:
```v
numbers := []int{ cap: 1000 }
mut numbers := []int{ cap: 1000 }
// Now adding new elements is as efficient as setting them directly
for i in 0 .. 1000 {
numbers << i