num-primes 0.3.0

A Rust Library For Generating Large Prime and Composite Numbers using num with a simplistic interface.
Documentation
1
2
3
4
5
6
7
8
9
10
11
12
13
14
use num_primes::{Generator,Factorization};

fn main() {
    // Generates New Unsighed Integer of 32 bits
    let uint = Generator::new_uint(32);
    
    // Prime Factorization    
    let factor = Factorization::prime_factor(uint);

    match factor {
        Some(factor) => println!("Largest Prime Factor: {}",factor),
        None => println!("No Prime Factors Found"),
    }
}