rs-math-fraction 0.1.0
Exact rational numbers with checked arithmetic
Install
cargo add rs-math-fraction --registry rupm
In Ruststudio: Packages, search for rs-math-fraction, Install.
Owner: Rust Studio. Licence: MIT OR Apache-2.0. Total downloads: 0. Published 2026-11-23.
Versions
- 0.1.0 2026-11-23
README
# rs-math-fraction Exact rational numbers with checked arithmetic Add it with `rupm add rs-math-fraction` (or `cargo add rs-math-fraction --registry rupm`). ```rust let a = rs_math_fraction::Fraction::new(1, 3)?; let b = rs_math_fraction::Fraction::new(1, 6)?; assert_eq!(a.checked_add(b)?.to_string(), "1/2"); ```