Define p ( n ) to be the product of all non-zero digits of n . For instance p ( 7 ) = 7 , p ( 3 9 ) = 2 7 , p ( 1 0 2 ) = 2 and so on. Find the greatest prime divisor of the following expression p ( 1 ) + p ( 2 ) + p ( 3 ) + . . . + p ( 9 9 9 )
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.
Note that p ( n ) can be defined as product of digits of number n with all 0 digit replaced with 1 . Let S ( n ) = k = 1 ∑ n p ( k ) . Then we have:
S ( 9 9 9 ) = k = 1 ∑ 9 9 9 p ( k ) = k = 1 ∑ 9 p ( k ) + k = 1 0 ∑ 9 9 p ( k ) + k = 1 0 0 ∑ 9 9 9 p ( k ) = k = 1 ∑ 9 k + k = 1 ∑ 9 k ( 1 + 1 + 2 + ⋯ + 9 ) + k = 1 0 0 ∑ 9 9 9 p ( k ) = S ( 9 ) + S ( 9 ) ( 1 + S ( 9 ) ) + k = 1 ∑ 9 p ( 1 0 0 k ) + k = 1 ∑ 9 k S ( 9 9 ) = S ( 9 ) ( S ( 9 ) + 2 ) + S ( 9 ) + S ( 9 ) 2 ( S ( 9 ) + 2 ) = S ( 9 ) ( S ( 9 ) + 2 + 1 + S ( 9 ) ( S ( 9 ) + 2 ) ) = 4 5 ( 2 1 6 3 ) = 3 3 ⋅ 5 ⋅ 7 ⋅ 1 0 3 0 replaced with 1 Note that S ( 9 9 ) = S ( 9 ) ( S ( 9 ) + 2 ) and S ( 9 ) = k = 1 ∑ 9 k = 2 9 ( 9 + 1 ) = 4 5
Therefore the greatest prime divisor of S ( 9 9 9 ) is 1 0 3 .
1 2 3 4 5 6 7 8 9 10 |
|
1 |
|
Problem Loading...
Note Loading...
Set Loading...
one dig numbers: p 1 = i = 1 ∑ 9 p ( i ) = i = 1 ∑ 9 i = 4 5
two digits numbers: p 2 = i = 1 0 ∑ 9 9 p ( i ) = i = 1 ∑ 9 p ( 1 0 i ) + i = 1 ∑ 9 j = 1 ∑ 9 p ( 1 0 i + j ) = i = 1 ∑ 9 i + i = 1 ∑ 9 j = 1 ∑ 9 ( i × j ) = i = 1 ∑ 9 i + i = 1 ∑ 9 i × j = 1 ∑ 9 j = p 1 + p 1 × p 1 = p 1 ( p 1 + 1 )
three digits numbers: p 3 = i = 1 0 0 ∑ 9 9 9 p ( i ) = i = 1 ∑ 9 ( j = 0 ∑ 9 9 p ( 1 0 0 i + j ) ) = i = 1 ∑ 9 ( p ( 1 0 0 i ) + j = 1 ∑ 9 9 p ( 1 0 0 i + j ) ) = i = 1 ∑ 9 p ( 1 0 0 i ) + i = 1 ∑ 9 ( j = 1 ∑ 9 9 p ( 1 0 0 i + j ) ) = p 1 + i = 1 ∑ 9 ( i × j = 1 ∑ 9 9 p ( j ) ) = p 1 + i = 1 ∑ 9 ( i × ( p 1 + p 2 ) ) = p 1 + p 2 × i = 1 ∑ 9 i = p 1 + ( p 1 + p 2 ) × p 1 = p 1 × ( p 1 + 1 ) 2
So i = 1 ∑ 9 9 9 p ( i ) = p 1 + p 2 + p 3 = 4 5 + ( 4 5 × 4 6 ) + 4 5 × ( 4 5 + 1 ) 2 = 4 5 × ( 1 + 4 6 + 4 6 2 ) = 4 5 × 2 1 6 3 = 4 5 × 2 1 × 1 0 3 = 3 3 × 5 × 7 × 1 0 3