In Chinese, numbers are written as follows:
For numbers above 10, it is expressed as the number of tens and the number of ones. If there is only one ten, you do not need to explicitly say one, and if there are no ones, you don't need to put anything after:
For numbers above 100, you use the same logic, but with the character
百. This time though, if there is only one hundred, you still need to write it out, and if there are no tens, you need to say
Your task is to convert these Chinese numerals into Arabic numerals. Given a number N in Chinese (
一 (1) <= N <=
九百九十九 (999)), convert it into an Arabic number.
Remember, this is code-golf, so the code with the smallest number of bytes wins.