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

all: updateimport () and []array

This commit is contained in:
yuyi
2020-04-26 19:49:31 +08:00
committed by GitHub
parent 7b39ab6d06
commit 9f4d498ff1
59 changed files with 181 additions and 254 deletions

View File

@ -10,11 +10,11 @@ fn main() {
min_str_len := 20
max_str_len := 40
println('Generating $sample_size strings between $min_str_len - $max_str_len chars long...')
mut bytepile := []byte
mut bytepile := []byte{}
for _ in 0 .. sample_size * max_str_len {
bytepile << byte(40 + rand.next(125 - 40))
}
mut str_lens := []int
mut str_lens := []int{}
for _ in 0 .. sample_size {
str_lens << min_str_len + rand.next(max_str_len - min_str_len)
}