sum up to exactly 10

This Question Was Asked By Microsoft

A number is considered perfect if its digits sum up to exactly 10. Given a positive integer n, return the n-th perfect number.

Write a function solve that have the following parameter(s):
1.) a = an integer

Example
Input:
3
Output:
7

Explanation
The input is 3 and if we add 7 then its sum up will be exactly 10.

Constraints
• The value of an integer should be greater than 0 and less than 10000.