6 releases
0.2.3 | Oct 7, 2024 |
---|---|
0.2.2 | Jul 14, 2024 |
0.1.2 | Jun 23, 2024 |
#117 in Value formatting
24 downloads per month
8KB
205 lines
Frequency Unit
A library for interaction with units of frequency.
Example
let freq = Frequency::from_mhz(1.0);
let freq2 = Frequency::from_mhz(2.0);
let freq3 = freq + freq2;
let a: f64 = freq3.to_mhz();
assert_eq!(a, 3.0);
let freq = Frequency::from_mhz(12.3456789);
assert_eq!(format!("{:<10.2}", freq), "12.35 MHz");
Dependencies
~465KB