pub trait Factoring: Sized {
    fn factor_events<T: FactoringEventSubscriptor<Self>>(
        self,
        events: T
    ) -> Vec<Self>; fn factor(self) -> Vec<Self> { ... } }
Expand description

Factor number into it’s prime factors

Required Methods

Factor number, while being notified as soon as any factors are found using the observer “events

Provided Methods

Factor number

Example
use facto::Factoring;
assert_eq!(60u64.factor(), vec![2u64, 2, 3, 5])

Implementations on Foreign Types

Implementors