题目描述
Problem Description
Given a Roman numeral \( B \), rearrange the characters of \( B \) to form the smallest possible number.
Input Format
A single line containing a Roman numeral \( B \).
Output Format
A single line containing a Roman numeral, which is the smallest number you can get by rearranging \( B \).
Sample Input and Output
Sample Input #1
VIII
Sample Output #1
VIII
Sample Input #2
VI
Sample Output #2
IV
Sample Input #3
III
Sample Output #3
III
Sample Input #4
LI
Sample Output #4
LI
Notes
\( 1 \leq B < 100 \).
Note that in this problem, I can only precede V and X if it is before a larger numeral. The input follows the same rules. (This is why the output for Sample #4 is LI instead of IL.)
输入格式
见题面 Input 部分
输出格式
见题面 Output 部分
样例输入
VIII
样例输出
VIII