{"id":21530683,"url":"https://github.com/razvangolan/romanmathoperations","last_synced_at":"2026-02-24T02:31:38.403Z","repository":{"id":262661729,"uuid":"887953479","full_name":"RazvanGolan/RomanMathOperations","owner":"RazvanGolan","description":"Perform arithmetic operations on Roman numerals without converting them into integers","archived":false,"fork":false,"pushed_at":"2024-11-23T09:24:42.000Z","size":141,"stargazers_count":3,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"main","last_synced_at":"2025-01-24T06:26:33.394Z","etag":null,"topics":["csharp","dotnet","roman-numerals"],"latest_commit_sha":null,"homepage":"","language":"C#","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/RazvanGolan.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2024-11-13T15:07:41.000Z","updated_at":"2024-12-31T08:16:46.000Z","dependencies_parsed_at":"2025-01-24T06:25:19.547Z","dependency_job_id":"9b97ee86-50ff-4bb9-a750-95397891dae1","html_url":"https://github.com/RazvanGolan/RomanMathOperations","commit_stats":null,"previous_names":["razvangolan/romanmathoperations"],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/RazvanGolan%2FRomanMathOperations","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/RazvanGolan%2FRomanMathOperations/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/RazvanGolan%2FRomanMathOperations/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/RazvanGolan%2FRomanMathOperations/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/RazvanGolan","download_url":"https://codeload.github.com/RazvanGolan/RomanMathOperations/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":244094266,"owners_count":20397020,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["csharp","dotnet","roman-numerals"],"created_at":"2024-11-24T02:09:46.452Z","updated_at":"2025-03-17T19:20:51.109Z","avatar_url":"https://github.com/RazvanGolan.png","language":"C#","funding_links":[],"categories":[],"sub_categories":[],"readme":"# RomanMathOperations\n\nThey say the Roman Empire fell because of political turmoil, but maybe it was just too hard to calculate battle logistics with numbers like `MMCMXCIX`. While we can't rewrite history, this project makes Roman math a little less daunting.\n\n\u003cp align=\"center\"\u003e\n  \u003cimg src=\"Fall_of_the_roman_empire.jpg\"  /\u003e\n\u003c/p\u003e\n\nThis is a C# project implementing arithmetic operations for Roman numerals **without converting them to integers**. It supports addition, subtraction, multiplication, and division, ensuring the rules and conventions of Roman numerals are strictly followed. The project also includes robust input validation and handles invalid or improperly formatted Roman numerals gracefully.\n\n## Features\n\n- **Arithmetic Operations**:\n    - **Addition**: Combines two Roman numerals into their sum.\n    - **Subtraction**: Computes the difference between two Roman numerals.\n    - **Multiplication**: Multiply two Roman numerals.\n    - **Division**: Divides one Roman numeral by another and provides both the quotient and remainder.\n\n- **Converter**:\n  - **ConvertRomanToDecimal**: Converts a Roman numeral string into its decimal (integer) equivalent.\n  - **ConvertDecimalToRoman**: Converts a decimal number into its Roman numeral representation, supporting values greater than 4000 by repeating the character `M`.\n\n- **Validation**:\n  - Detects invalid characters in Roman numerals (valid characters are `I`, `V`, `X`, `L`, `C`, `D`, `M`).\n  - Ensures input follows valid Roman numeral formatting rules (e.g., prevents invalid sequences like `XXXX`).\n\n- **Custom Exceptions**:\n    - `InvalidRomanCharacter`: Raised when an invalid character is found in a Roman numeral.\n    - `InvalidRomanFormat`: Raised when Roman numerals are not formatted correctly.\n    - `InvalidRomanSubtractionException`: Raised when attempting to subtract a larger number from a smaller one.\n    - `ResultIsZeroException`: Raised when an operation results in zero, which did not exist in Roman numeral systems.\n\n## Tests\n\n**The project includes comprehensive unit tests covering**:\n- Arithmetic operations (addition, subtraction, multiplication, and division).\n- Validation of invalid characters and formats.\n- Exception handling for invalid operations.\n- Randomly generated test cases to ensure correct results for various operations and conversions between Roman numerals and decimal numbers.\n\n## License\n\nThis project is licensed under the MIT License. See the [LICENSE](LICENSE) file for details.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Frazvangolan%2Fromanmathoperations","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Frazvangolan%2Fromanmathoperations","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Frazvangolan%2Fromanmathoperations/lists"}