Roman Numeral Converter

This is just a quick and basic hack to convert Roman numerals to decimal format. In case you're not familiar, here's how these suckers work:

Symbol Value
I 1
V 5
X 10
L 50
C 100
D 500
M 1000

You put them together in combinations. E.g., XIII is 13, XV is 15, and XIV is 14.


Here's the script. It's pretty naive (i.e. it does no validation of the Roman numeral), but it works.


Was this page useful to you? Loading...