3 ms·
Clojure Kata #3 – Roman Numerals
- platz 12y ago"The reason I wanted to try the solution that I posted is that I didn't want to include IV, IX, XC, ... into the list of symbols as they are made up of base symbols (just for the sake of the exercise)." An interesting choice - it seems to make the problem harder than it should be. This is really solvable in about 6-8 lines of code otherwise.
- jollyman 12y agoWhen learning a Lisp, you have to be careful of the habit of placing ending parenthesis/brackets on new lines like you would in C and Java.
- diego 12y agoIf you'd like to see interesting solutions to this problem, I recommend solving this 4clojure exercise: http://www.4clojure.com/problem/104 http://www.4clojure.com/problem/104 and then looking at solutions by experienced Clojurians. Some are code golf but still worth understanding (e.g chouser's, who is one of the authors of The Joy of Clojure).