Let S be the set of all 21-digit positive integers that can be composed from the digits 1 , 2 , 3 , 4 , 5 , 6 , 7 , 8 , 9 (repetition is of course allowed, but not all digits must necessarily appear). Let N be an element of S chosen uniformly at random, and let A be the product of all the digits of N .
If P is the probability that A is divisible by 2 1 , then find ⌊ 1 0 0 0 P ⌋ .
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.
Why u give 21.it becomes too big
Log in to reply
Well, I guess I could have gone with, say, 10-digit numbers, but that would still require a calculator at the end. I just liked the repetition of 21, i.e., 21-digit numbers whose digit product is divisible by 21.
Log in to reply
Yeah that's a matching
Log in to reply
@Kushal Bose – For N -digit numbers the probability is P = 1 − ( 9 8 ) N − ( 3 2 ) N + ( 9 5 ) N and we can work this out for much larger values of N than 2 1 .
Log in to reply
@Mark Hennings – We have to use calculators .Without using how it can be done ?
Log in to reply
@Kushal Bose – So what is wrong with using a calculator? I thought you were concerned because numbers like 9 N were getting large - 9 1 0 5 causes a math overflow on most calculators, but there is no problem calculating ( 9 8 ) 1 0 5 .
Log in to reply
@Mark Hennings – Yes calculating fractions is not a problem at all
I used a c++ program to evaluate that expression for P ;)
Problem Loading...
Note Loading...
Set Loading...
For the product A to be divisible by 2 1 at least one of the 21 digits must be divisible by 3 , i.e., must be one of 3 , 6 , 9 , and at least one of the digits must be 7 . It will be easier though to first count the number of elements of S that are n o t divisible by 2 1 .
There are 5 2 1 elements of S that have no digits that are 7 or are divisible by 3 , (i.e., those 21-digit integers formed using the digits 1 , 2 , 4 , 5 , 8 ).
Next, as there are 8 2 1 elements that do not have 7 as a digit, there are 8 2 1 − 5 2 1 elements that have at least one digit that is a multiple of 3 but have no 7 .
Finally, as there are 6 2 1 elements that have none of 3 , 6 , 9 as digits, there are 6 2 1 − 5 2 1 elements that have none of 3 , 6 , 9 as digits but do have at least one 7 .
Thus there are 5 2 1 + ( 8 2 1 − 5 2 1 ) + ( 6 2 1 − 5 2 1 ) = 8 2 1 + 6 2 1 − 5 2 1 elements of S that are not divisible by 2 1 . As S has 9 2 1 elements in total, the probability P that the product A associated with a randomly chosen elements N of S is divisible by 2 1 is
P = 9 2 1 9 2 1 − ( 8 2 1 + 6 2 1 − 5 2 1 ) = 0 . 9 1 5 5 0 9 8 0 2 . . . , and so ⌊ 1 0 0 0 P ⌋ = 9 1 5 .