pub trait GetDecimal {
    fn get_decimal(&self) -> u128;
}
Expand description

A trait to losslessly get the decimal part of a float

Examples

use lemonmath::helper::GetDecimal;
 
let x = 1.12;
 
assert_eq!(x.get_decimal(), 12);

Required methods

Implementations on Foreign Types

Implementors