Given two integers ‘n’ and ‘sum’, find count of all n digit numbers with sum of digits as ‘sum’. Leading 0’s are not counted as digits. Print your output % 10^9+7.
The first line contains an integer T, depicting total number of test cases.
Then following T lines contains 2 integers n and sum.
Print the number of digits. Print -1 if answer is not possible.
Explaination: 2 numbers 11 and 20.
If you have purchased any course from GeeksforGeeks then please ask your doubt on course discussion forum. You will get quick replies from GFG Moderators there.