To solve this problem you can use regex. However, a simple replacement can also do the trick. According to rules given these replacements are needed to acquire minimal form: DCCCC to CM, LXXXX to XC and VIIII to IX ,IIII to IV, XXXX to XL and CCCC to CD. So the difference in the [...]
