We use cookies to ensure you have the best browsing experience on our website. Please read our cookie policy for more information about how we use cookies.
I was failing all but the first test case until I realized that I wasn't accounting for the example case given in the description (IM should be CMXCIX) -- for that case you need to remember I can be subtracted from 10 as well as 5.
Cookie support is required to access HackerRank
Seems like cookies are disabled on this browser, please enable them to open this website
Project Euler #89: Roman numerals
You are viewing a single comment's thread. Return to all comments →
I was failing all but the first test case until I realized that I wasn't accounting for the example case given in the description (IM should be CMXCIX) -- for that case you need to remember I can be subtracted from 10 as well as 5.