logo
Interview
    Interview Guide
    Coding Problems List
Sponsored: Coursera
Problems

Integer to Roman

Problem

Given an integer, convert it to a roman numeral.

The number is guaranteed to be within the range from 1 to 3999.

Example

4 -> IV
12 -> XII
21 -> XXI
99 -> XCIX

More examples at: http://literacy.kent.edu/Minigrants/Cinci/romanchart.htm

Note

What is Roman Numeral?

Online Judge