next up previous
Next: The Output Up: Roman Numerals Previous: Roman Numerals

The Input

The input will consist of a sequence of integers in the range 1 to 100, terminated by a zero. For each such integer n, except the final zero, determine the number of different types of characters needed to number the prefix pages 1 through n with Roman numerals.



ACM Programming Contest Account
Mon Jan 24 15:47:44 EST 2000