In a series of numbers where each number is such that the sum of its digits equals 10. Given an integer value 'N', your task is to find the N-th positive integer whose sum of digits equals to 10.
The first line contains an Integer 'T' which denotes the number of test cases/queries to be run.
Then the test cases follow.
The first line of input for each test case/query contains an integer N, the Nth number to find.
For each test case, print the N-th positive integer whose sum of digits equals 10.
Output for every test case will be printed in a separate line.
You do not need to print anything, it has already been taken care of. Just implement the given function.
1 <= T <= 100
1 <= N <= 10^7
Time Limit: 1sec
Sample Input 1:
Sample Output 1:
Explanation of Sample Input 1:
Since N=1 here, therefore, the first number having a sum of digits equal to 10 is 19. Therefore, the output here is 19.
Since N=4 here, therefore, The first four numbers having a sum of digits equal to 10 are 19, 28, 37, and 46. Therefore, the output here becomes 46.
Sample Input 2:
Sample Output 2: