mirror of
https://github.com/vlang/v.git
synced 2023-08-10 21:13:21 +03:00
examples: add random_ips.v
This commit is contained in:
parent
01dc267e20
commit
0e852e9c81
10
examples/random_ips.v
Normal file
10
examples/random_ips.v
Normal file
@ -0,0 +1,10 @@
|
|||||||
|
import rand
|
||||||
|
import time
|
||||||
|
|
||||||
|
fn main() {
|
||||||
|
rand.seed(time.now().uni)
|
||||||
|
|
||||||
|
for _ in 0..10 {
|
||||||
|
println('${rand.next(255)}.${rand.next(255)}.${rand.next(255)}.${rand.next(255)}')
|
||||||
|
}
|
||||||
|
}
|
Loading…
x
Reference in New Issue
Block a user