Enable Javascript in your browser and then refresh this page, for a much enhanced experience.
First solution in Clear category for Roman Numerals by M0PK0BKA
def checkio(data):
arabic = [1000, 900, 500, 400, 100, 90, 50, 40, 10, 9, 5, 4, 1]
roman = "M CM D CD C XC L XL X IX V IV I".split()
res = ""
for a, r in zip(arabic, roman):
m, data = divmod(data, a)
res += r * m
return res
Jan. 30, 2023
Comments: