my guess without thinking...at least once (99.9)
or do you mean only once?
must be close to 100%, once you get to huge numbers, almost every one of them must have a 9 in them somewhere
I'll explain the formula. The chance of the dice not rolling on the number is .99 so that hundred times is .99^100. That is the chance of not rolling on the number after 100 throws, so the reverse of that chance is rolling at least once on the number, and that is 1- that chance.
Thanks alot
must be close to 100%, once you get to huge numbers, almost every one of them must have a 9 in them somewhere
Correct! It's virtually 100%
@rooperi: my intuition would say 10%. But it is better to say 10% for each consecutive number. That implies that it is a cumulative result.
The formula (in php) becomes:
<?php
$total = 0;
$tmp = 0;
for($n = 1; $n<31; $n++){
$total = 0;
for($i = 0; $i < $n; $i++){
$tmp = pow(9,$i) * pow(10,($n - $i - 1));
if($total === 0){
$total = $tmp;
}else{
$total = $total + $tmp;
}
}
print "number of nines under the power of 10 of ".$n." is: ".$total."<br/>";
}
?>
This is the output of the above function (in which I have put 31 as the max.):
number of nines under the power of 10 of 1 is: 1
number of nines under the power of 10 of 2 is: 19
number of nines under the power of 10 of 3 is: 271
number of nines under the power of 10 of 4 is: 3439
number of nines under the power of 10 of 5 is: 40951
number of nines under the power of 10 of 6 is: 468559
number of nines under the power of 10 of 7 is: 5217031
number of nines under the power of 10 of 8 is: 56953279
number of nines under the power of 10 of 9 is: 612579511
number of nines under the power of 10 of 10 is: 6513215599
number of nines under the power of 10 of 11 is: 68618940391
number of nines under the power of 10 of 12 is: 717570463519
number of nines under the power of 10 of 13 is: 7458134171671
number of nines under the power of 10 of 14 is: 77123207545039
number of nines under the power of 10 of 15 is: 794108867905351
number of nines under the power of 10 of 16 is: 8146979811148159
number of nines under the power of 10 of 17 is: 83322818300333431
number of nines under the power of 10 of 18 is: 849905364703000879
number of nines under the power of 10 of 19 is: 8649148282327007911
number of nines under the power of 10 of 20 is: 8.7842334540943E+19
number of nines under the power of 10 of 21 is: 8.9058101086849E+20
number of nines under the power of 10 of 22 is: 9.0152290978164E+21
number of nines under the power of 10 of 23 is: 9.1137061880347E+22
number of nines under the power of 10 of 24 is: 9.2023355692313E+23
number of nines under the power of 10 of 25 is: 9.2821020123081E+24
number of nines under the power of 10 of 26 is: 9.3538918110773E+25
number of nines under the power of 10 of 27 is: 9.4185026299696E+26
number of nines under the power of 10 of 28 is: 9.4766523669726E+27
number of nines under the power of 10 of 29 is: 9.5289871302754E+28
number of nines under the power of 10 of 30 is: 9.5760884172478E+29
Counterintuitive for me, yet correct. Thanks for the puzzle with the unexpected result!
If a rolled a dice and there was a 1/100 chance of me landing on the number I want it to land on, and I rolled it 100 times what is the percentage of me atleast landing on it once?