End of a 999-Digit Number

A 999-digit number starts with 9. Every 2 consecutive digits is divisible by 17 or 23. There are 2 possibilities for the last 3 digits. What is the sum of these 2 possibilities?

Details and assumptions

If you believe that the sum is over 999, enter your answer as 999.

If the number is 12345, then every 2 consecutive digits refers to the number 12, 23, 34 and 45.

The number starts with 9 if the leftmost digit is a 9.


The answer is 751.

This section requires Javascript.
You are seeing this because something didn't load right. We suggest you, (a) try refreshing the page, (b) enabling javascript if it is disabled on your browser and, finally, (c) loading the non-javascript version of this page . We're sorry about the hassle.

12 solutions

Emily Jia
May 20, 2014

ince the number is 999 999 digits long, chances are that the digits are not randomly arranged; we can look for a pattern. - Two-digit multiples of 17 17 are: 17 , 34 , 51 , 68 , 85 17, 34, 51, 68, 85 , Two-digit multiples of 23 23 are: 23 , 46 , 69 , 92 23, 46, 69, 92 . Every two consecutive digits must be one of these numbers.

We know that the leftmost digit is 9 9 , so let's see how far we can get. Let the first seven digits of the number be: 9 a b c d e f . . . 9abcdef... The number 9 a 9a (where 9 9 is in the tens' place and a is in the units place) must be 92 92 , since 92 92 is the only number from the two lists with a 9 9 in the tens' place. Thus our number is 92 b c d e f . . . 92bcdef... Similarly, the number 2 b 2b must be 23 23 , since 23 23 is the only number from the two lists with a 2 2 in the tens' place. Thus our number is 923 c d e f . . . 923cdef... Using this logic, we eventually get to 92346 e f . . . 92346ef... There are two possibilities
- First, e = 8 e=8 : Continuing, we get 923468517... 923468517... but then no two-digit number that starts with 7 7 is divisible by 17 17 or 23 23 , so this case is impossible, since the number is 999 999 digits long
- Second, e = 9 e=9 : Continuing, we get 9234692346... 9234692346... it repeats! Thus, e = 9 e=9 and our 999 999 digit number repeats 92346 92346 over and over again. Since the pattern is 5 5 digits long, we know that the 999 5 198 = 9 999 - 5 \cdot 198 = 9 th number is 9 9 .

The last nine digits look like: 92346 e f g h 92346efgh - Obviously, the last four digits can continue the pattern and be 9234 9234 , which is the case when e = 9 e=9 . - However, e e can also equal 8 8 . Before, we rejected the case when e = 8 e=8 because it stopped at 7 7 before the number could reach 999 digits. Is this still the case? Let e = 8 e=8 : then the last nine digits are 923468517 923468517 . It works! The pattern ends just as the 999 999 digit number ends.

Thus, the sum of the two possibilities for the last three digits is: 234 + 517 = 751 234+517= \boxed{751} and we are done.

When working on the problem, many students were stuck at 923468517 923468517 and couldn't see how to get the 2nd solution. They forget that they may choose to exit the loop at any point in time.

For those familiar with the Beatty Sequence , notice that 1 1.7 + 1 2.3 1.023 \frac {1}{1.7} + \frac {1}{2.3} \approx 1.023 , which is why these numbers work so well for the problem setting.

Calvin Lin Staff - 7 years ago
Nikhil Mahajan
May 20, 2014

Since, any two consecutive digits have to be divisible by 17 or 23, all the possibilities would have to be integer multiples of 17 and 23 less than 100. These are 17, 23, 34, 46, 68, 69, 85 and 92.

Since the problem states that the number begins with a 9, the possible patterns are:

92346 repeating - using the numbers 92-23-34-46-69

923468517 - this pattern ends at 7 because there is no two-digit number that begins with 7 in the list above.

Since the second pattern is only 9 digits long, it can only appear at the end of the 999-digit number. Which means that the first pattern repeats for the first 995 digits.

We know from the first pattern, therefore, that the 995th digit will be 6 (since every 5th digit is 6). Therefore, the remaining 4 digits can either be 9234 or 8517.

Therefore, the sum of the two possibilities for the last three digits is
234 + 517 = 751

Erick Wong
May 20, 2014

Tracing through the possibilities for each successor digit, we get the directed graph 9->2->3->4->6*->8->5->1->7. The digit 7 has no possible successor, while 6 uniquely has the choice of looping back to 9 or going forward to 8.

Because of the dead end at 7, the only way to find a path of length 999 in this graph starting is to stay in the cycle for almost as long as possible: if we stay in the length 5 cycle completely, the digit pattern will end as if it was only 4 digits long: 9 2 3 4. If we leave the cycle at that same moment, the last 4 digits would instead be 8 5 1 7. The two possible endings are therefore 234 and 517, which sum to 751.

Rohan Singh
May 20, 2014

We know that the number has 999 digits, first digit is 9 and any two consecutive digits have to be divisible by either 17 or 23.

we can see that a 2 digit number starting with 9 is only divisible by 23 and the number is 92.Working similarly, the next digit has to be 3(again the number is divisible by 23 and 17 does not have multiple in twenties).

So, we can see that numbers till 5(from left) places have to be, 9 2 3 4 6

After that there is a possibility of 8(68 is divisible by 17) or 9(69 is divisible by 23).

Let us first take the no.at 6th position to be 8.

So, the further digits have to be 5,1,7

But after that, since neither 23 nor 17 has a multiple in seventies, we cannot form the further digits according to given pattern.

Therefore, the 6th digit has to be 9 and so the pattern repeats itself.

Since the pattern repeats after 5 digits, till 995th digit,we have same pattern.

995th digit is 6.

Therefore the next 4 digits have 2 possibilities,i.e. 8517(valid this time since number ends after these 4 only.So, no violation of initial condition) and 9234.

Therefore the 2 possibilities for last 3 digits are 517 and 234.

Therefore answer=234+517=751

Ahmed Bakr
May 20, 2014

2 digits multiple of 17 or 23 are:

17, 23, 34, 46, 51, 68, 69, 85, 92 .

for a number that starts with 9 to form 999 digits, the number should start

note: if we used the number 68 will cut the series so it can only used at the end of the number
as 68517 no multiple of 17 or 23 has 7 in the tens digit

9234692346 this 10 digits will be repeated to form 990 digit for the last 9 digits 923469234 or 923468517 we can now use 68 as there is no need to continue the series.

so the probability of the last 3 digits are 234, 517 and their sum are 751

the 2-digit numbers divisible by 17 are 17,34,51,68,85 the 2-digit numbers divisible by 23 are 23,46,69,92

start arranging the digits 92346 we see that after 6 if we put 8 then series will end i-e 923468517 no 2 digit number start with 7 divisible by 17 or 23. so we have to put 9 only to continue the series .The pattern of 5 digits run up to 199 times completely remaining only 4 digits so we have two option to complete the number i-e 9...68517 & 9....69234 sum of last three digits from both series is 517+234=751.

Shubham Raj
May 20, 2014

Every 2 digits are divisible by either 17, or 23

Let us see 2 digit divisors of 17 and 23; 17: 17, 34 ,51, 68 ,85

23: 23, 46 , 69 , 92

One thing we should note here is that first digit of all 2 digit divisors are different except for 6.

We are given 1st digit of 999-digit number is "9" So obviously next digit is 2 , continuing same way, we can easily see first 5 digits will be : 92346 Now from here we can have either 9 or 8 for the next digit. 1st case : 8

Filling up next digit as 8, we can try to build further : 923468517_ Here we get stuck, as no 2 digit divisor from the sample space starts with 7. Hence there is a halt, thus 6th digit can not be 8. Hence it must be 9

Case 2: 9 9234692346 ....

Thus, every 5 digits are repeated ; we can easily say that first 995 digits will 92346 written 199 times

Next digit now, can either be 8 or 9 since we now only have to deal with 4 remaining digits, If that is 8, we have last 4 digits as 8517 If that is 9, we have last 4 digits as 9234

Thus the 2 possibilities for last 3 digits are 517 and 234

=>517 + 234 = 751

Sam Dreilinger
May 20, 2014

First, list the multiples of 17 and 23 that are less than 100. They are:

{17, 23, 34, 46, 51, 68, 69, 85, 92}

Now start to write the 999 digit number down, starting with the left-most digit (that is, the digit in the 10^998 place). The problem states it must be a 9, so the number looks like

9xxx...xx

Now, any two consecutive digits must be a number from the list above. So the only acceptable next digit is 2. So far we have

92xxx...xx

Proceeding similarly, it's easy to see that, starting from the left, the first five digits are forced to be 92346. We have a choice for the next digit, because the list above contains both 68 and 69. Suppose we choose 8. Our number would look like

923468517xxx...xxx

where the 5, 1, and 7 were forced using the same process as above. But now there's a problem. The list above doesn't contain any numbers beginning with a 7, so any digit we put next will cause our number to have two consecutive digits that aren't a multiple of 17 or 23. Therefore, we must choose to put a 9 after the 6. Now we're back where we started with a 9, so this string of 5 digits will repeat itself for a while. Our number looks like

923469234692346...

Inspecting this number, it's easy to see that, counting from the left, we encounter a 6 in the fifth spot, the tenth spot, the fifteenth spot, the twentieth spot, and so on.

We're interested in the right-most three digits of this number. Using the logic above, we can see that the right-most end of this number looks like

...92346xxxx

Using the list at the top, the two choices for the last 4 digits are 8517 or 9234. The problem asks for the sum of the last three digits which is given by

517 + 234 = 751.

Adán Medrano
May 20, 2014

First, we must look for the multiples of 17 17 and 23 23 that have two digits in its decimal representation. For the first, we have 17 , 34 , 51 , 68 , 85 17, 34, 51, 68, 85 and for the second, we have 23 , 46 , 69 , 92 23, 46, 69, 92 . We see our number starts with 9 9 , so the first obligatory "chain of consecutive digits is 92346 and then, we have 2 possibilities for the following number, as it may be either 8 or 9, but if 8 follows, then the chain 8517 follows, and we have no more possibilities for the next number, so, in the first 995 digits, the chain 92346 must appear, and for the last 4 digits, we may have either 8517 or 9234, so our options for the last 3 digit numbers are 517 and 234, and their sum is 751.

When working on the problem, many students were stuck at 923468517 923468517 and couldn't see how to get the 2nd solution. They forget that they may choose to exit the loop at any point in time.

For those familiar with the Beatty Sequence , notice that 1 1.7 + 1 2.3 1.023 \frac {1}{1.7} + \frac {1}{2.3} \approx 1.023 , which is why these numbers work so well for the problem setting.

Calvin Lin Staff - 7 years ago

17 Times Table(2 digits long ones): 17,34,51,68,85 23 Times Table: 23,46,69,92

So the first 2 digits would be 92 but is it supposed to be a multiple of 17 next? because there are no multiples of 17 starting with a 2. Using the 23 it would then go 923 Then the 34 to get 9234 Then the 46 to get 92346 Then it could either be 69 or 68 giving you 923469 or 923468 Then the 85 and 92 to get 9234692 or 9234685 The first sequence would keep repeating, giving you 9,23469,23469,23469 Continuing the second sequence with the 85 would give you 9234685 Then 51 to get 92346851 Then 17 to get 9,23468517 but there are no 2 digit multiples of 17 or 23 so this sequence cannot continue.

Using the first sequence 9,23469,23469,23469... There are 999 digits so -1 for the 9 at the beginning to get 998 The repeating sequence is of length 5 Divide the 998 digits by 5 and take the remainder: 3 so the last 3 digits could be 234 or you could use the 23468517 from the second sequence at the end which is 8 digits long so it would have 1 less repetition of the other 5 length sequence. So 234+517=751

Rohan Rao
May 20, 2014

I solved this question with logical reasoning and analysis of the restrictions. First, write down the multiples of 17 and 23 that are 2 digit numbers. Let the sets be

S1: set of all 2-digit multiples of 17 = { 17, 34, 51, 68, 85}

S2: set of all 2-digit multiples of 23 = { 23, 46, 69, 92}

The 999-digit number starts with 9, and the rest of the digits are derived from the above sets such that the 2-digit numbers they form with the digits before and after them are either multiples of 17 or 23.

N = 9...2...3...4...6... * 9

OR

N = 9...2...3...4...6...8...5...1...7...???

Note that after the first five digits, the sequence of digits will repeat (marked with * for repetition.) We do not choose the second sequence since there is no member in either set that begins with a 7, so the number remains incomplete. However, this data will be used to find the last few digits.

The sequence of 9...2...3...4...6 will continue till 995 digits are written down. There are two possible ways to complete the number. Either we can continue this sequence for another 4 digits as 9...2...3...4 or we can write the digits of the second sequence as it cannot cause a problem at this stage. Thus, we can also have 8...5...1...7.

There are 2 possibilities for the last three digits, i.e, 234 and 517. Thus, the final answer is 751.

Calvin Lin Staff
May 13, 2014

The 2-digit multiples of 17 are 17, 34, 51, 68, and 85. The 2-digit multiples of 23 are 23, 46, 69, and 92. If 68 ever appears as 2 consecutive digits, then the remaining numbers are 68517, after which we cannot continue the number. Hence, the initial string of digits must be 92346 repeated. This gives that the 995th digit is a 6, and it may be continued as 68517 or 69234. Thus the answer is 517 + 234 = 751 517+234 = 751 .

0 pending reports

×

Problem Loading...

Note Loading...

Set Loading...