Hide

Problem C
Spell it Out

You find yourself with family and helping your little cousin practice their spelling. Currently they are stuck on spelling out numbers - a difficult problem you remember well! They are asking you to give them some examples of the correct spellings, so you thought it might help to write up a quick program, that when given a number $N$, prints the correct English spelling of it.

Input

The only input consists of a number $N$, where $0 \le N \le 99$.

Output

Return a string $S$ which consists of the lowercase English spelling of $N$. Numbers that consist of multiple words should be seperated by a hyphen (-) and not a space. All possible words with their correct spellings are listed below.

Notes

All possible words used to spell out the numbers are: zero, one, two, three, four, five, six, seven, eight, nine, ten, eleven, twelve, thirteen, fourteen, fifteen, sixteen, seventeen, eighteen, nineteen, twenty, thirty, forty, fifty, sixty, seventy, eighty, ninety.

Sample Input 1 Sample Output 1
7
seven
Sample Input 2 Sample Output 2
11
eleven
Sample Input 3 Sample Output 3
59
fifty-nine

Please log in to submit a solution to this problem

Log in