gen-rand-num 0.2.0

A simple Rust crate to generate random numbers within a specified range.
Documentation
1
2
3
4
5
6
7
8
9
10
11
12
13
pub mod gen_rand_num;
pub use gen_rand_num::gen_rand_num;

#[cfg(test)]
mod tests {
    use super::*;

    #[test]
    fn test_gen_rand_num() {
        let rand_num = gen_rand_num(1, 100);
        assert!(rand_num >= 1 && rand_num <= 100);
    }
}