Cashier's Problem

5

1 votes
Hard
Problem

A Cashier in a small departmental store has amnesia. He forgets mathematical numbers corresponding to the english value and he is feared to inform his manager. He wants you - the future "Software Developer" to design a program that can convert the given numeric digit 'n' into corresponding words so that he can give back the change to the customer and retain his job.

Constrain :

0 <= n <= 10000000

Sample Input 1:

123

Sample Output 1:

one hundred and twenty three

Sample Input 2:

1009000

Sample Output 2:

one lakh nine thousand

 

Sample Input
123
Sample Output
one hundred and twenty three
Time Limit: 5
Memory Limit: 256
Source Limit:
Editor Image

?