Skip to main content

checked_factorial

Function checked_factorial 

Source
pub fn checked_factorial(n: u64) -> Result<u128, GeodeError>
Expand description

Returns n! using checked u128 arithmetic.

ยงErrors

Returns GeodeError::ArithmeticOverflow when the factorial no longer fits in u128.