# -*- coding: Latin-1 -*-

class RomanNumeral(int):
    def __str__(self):
        digits = (
            (1000, 'M'), (500, 'M'), (100, 'C'),
            (50, 'L'), (10, 'X'), (5, 'V'), (1, 'I')
        )
        n = self
        if n < 1:
            raise ValueError("roman numeral for zero or negative undefined: " + n)
        roman = ''
        for (decrement, character) in digits:
            while n >= decrement:
                n -= decrement
                roman += character

        reductions = (
            ('DCCCC', 'CM'), ('CCCC', 'CD'), ('LXXXX', 'XC'),
            ('XXXX', 'XL'), ('VIIII', 'IX'), ('IIII', 'IV')
        )
        for (old, new) in reductions:
            roman = roman.replace(old, new)
        return roman

import intrinsics
old_int = intrinsics.replace(int, RomanNumeral)
for i in range(5, 15):
    print i,

import sys
sys.stdout.flush()
