Kata Roman numbers
We had the chance to try for an hour this kata in the Wecodefest 2019 in Mod mode. We didn't have time to finish it, so I decided to do it by myself.
I am going to reproduce the steps we did during the kata and then I will try to continue by myself.
Restriction: Consider 1000 as the maximum number.
I did several iterations till I've got blocked when I added 99 to the tests. I have created the branch by-myself as I am going some iterations in order to implement a proper solution.
I checked this one, and I iterated mine in order to match it. I don't like to have hardcoded the roman values for 4, 9, 40, 90, 400 and 900 but it works.
To be continue...
More stuff can be done:
- Do the inverse operation (from roman to decimal)
- Avoid recursion
- Implement a solution with the special decinals hardcoded (4, 9, ...)