Crate ramenon

Source
Expand description

Roman numerals converter

§Quick Start

use ramenon::*;

let int = 3_888;
let roman = "MMMDCCCLXXXVIII";

let roman_to_int = to_int(roman);
let int_to_roman = to_roman(int);

assert_eq!(int, roman_to_int.unwrap());
assert_eq!(roman, int_to_roman.unwrap().as_str());

Constants§

  • The largest value that can be represented by roman numerals.

Functions§

  • Converts a roman numeral to an integer, returning None if the provided roman numeral is invalid.
  • Converts an integer to a roman numeral, returning None if the provided integer is invalid.