Challenge: Find the Largest Number
A girl lost the key to her locker (Note: The key is only numeric). She remembers the number of digits
N and the sum
S of all the digits of her password. She also knows that her password is the largest number of
N digits that can be possible with the given sum
Implement a function that helps her retrieve her key.
The inputs are the number of digits and the sum of those digits.
The output prints the largest number that can be created (or the key).
number_of_digits = 3, sum_of_digits = 20
Note: If no number is possible for a combination of
number_of_digits, then simply print