Three not necessarily distinct positive integers between and , inclusive, are written in a row on a blackboard. Then, the numbers, without including any leading zeros, are concatenated to form a new integer . For example, if the integers written, in order, are , , and , then (and not ). Determine the number of possible values of .
Problem 1324
Official solution
Solution:
Answer:
We will divide this into cases based on the number of digits of .
- Case 1: digits. Then each of the three numbers must have two digits, so we have choices for each. So we have a total of possibilities.
- Case 2: digits. Then, exactly one of the three numbers is between and , inclusive. We consider cases on the presence of s in .
- No s. Then, we have choices for each digit, for a total of choices.
- One . Then, the can be the second, third, fourth, or fifth digit, and choices for each of the other digits. Then, we have a total of choices.
- Two s. Then, there must be at least one digit between them and they cannot be in the first digit, giving us choices for the positioning of the s. Then, we have a total of choices.
So we have a total of choices in this case.
- Case 3: digits. Again, we casework on the presence of s.
- No s. Then, we have choices.
- One . Then, the can go in the second, third, or fourth digit, so we have choices.
So we have a total of choices in this case.
- Case 4: digits. Then, we cannot have any s, so we have a total of choices.
Hence, we have a total of choices for .