Update appNew update is available. Click here to update.

Convert Number To Words

Posted: 15 Jan, 2021
Difficulty: Easy


Try Problem

You are given an Integer ‘N’ you have to convert the integer to words.

For example you are given integer N = 2234 then you have to return the string “two thousand two hundred and thirty four”.

Input format :
The first line of input contains an integer ‘T’ denoting the number of test cases.

The next ‘T’ lines represent the ‘T’ test cases.

The first line of each test case contains a single integer N denoting the integer.
Output format :
For each test case, print a string representing the integer in words.
Note :
You don’t have to print anything; it has already been taken care of. Just implement the given function. 
Constraints :
1 <= T <= 100
1 <= N <= 999999999

Time Limit: 1 sec