Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR RUST

rust sleep

use std::{thread, time};

loop {
    let ten_millis = time::Duration::from_millis(10);
    let now = time::Instant::now();
    thread::sleep(ten_millis);
}
Source by doc.rust-lang.org #
 
PREVIOUS NEXT
Tagged: #rust #sleep
ADD COMMENT
Topic
Name
2+8 =