1
0
dust/examples/async.ds

20 lines
347 B
Plaintext
Raw Normal View History

2023-12-01 23:20:33 -05:00
create_random_numbers = <fn int> |count| {
numbers = []
2023-11-03 23:42:10 -04:00
while (length numbers) < count {
numbers += (random_integer)
}
(output "Made " + (length numbers) + " numbers.")
2023-11-03 23:42:10 -04:00
}
2023-11-30 09:48:56 -05:00
(output "This will print first.")
2023-11-03 23:42:10 -04:00
async {
(create_random_numbers 1000)
(create_random_numbers 100)
(create_random_numbers 10)
}
(output "This will print last.")