Registry / Library

library · v0.1.0
BatchQuota
Bound the next batch of an interrupted command.
Use BatchQuota
use vendor::batchquota::batchquota;
Run the example
nest demo batchquota@0.1.0
blyxc native-run batchquota-demo/main.blyx
Example source and expected output
use vendor::batchquota::batchquota;
fn main() {
let done = 4.0;
let total = 10.0;
let limit = 3.0;
let result = batchquota_allow(done, total, limit);
if len(result) == 0 { println!("invalid"); return; }
let mut i = 0;
while i < len(result) {
println!(at(result, i));
i += 1;
}
}
Expected output
4
3
3
Published versions
| Version | Package | Source commit | SHA-256 |
|---|---|---|---|
| 0.1.0 | Download ZIP | 1470b15477 | 2bda7dce0aafc904193afc075100762fe4cffdabe745553917719e0e4eb8986d |