If I took all the numbers from one to one billion:
- How many of them contain at least one '1'?
- If I wrote them out in one long line, how many 1 digits would there be?
N(x) = number of numbers <1 billion that satisfy condition x
N(at least 1) = 1 billion - N(no ones)
= 1billion - 9^9
= 612 579 511
9^8 contain 1 one
9^7 contain 2 ones
9^6 contains 3 ones
9^5 contains 4 ones
9^4 contains 5 ones
9^3 contain 6 ones
9^2 contains 7 ones
9 contain 8 ones
1 contains 9 ones
=3 868 151 445 without counting 1 billion
=3 868 151 446 if you include 1 billion
<TABLE style="WIDTH: 125pt; BORDER-COLLAPSE: collapse" cellSpacing=0 cellPadding=0 width=167 border=0 x:str>
<COLGROUP>
<COL style="WIDTH: 125pt; mso-width-source: userset; mso-width-alt: 6107" width=167>
<TBODY>
<TR style="HEIGHT: 12.75pt" height=17>
<TD style="BORDER-RIGHT: #d4d0c8; BORDER-TOP: #d4d0c8; BORDER-LEFT: #d4d0c8; WIDTH: 125pt; BORDER-BOTTOM: #d4d0c8; HEIGHT: 12.75pt; BACKGROUND-COLOR: transparent" align=right width=167 height=17 x:num="3868151445"></TD></TR></TBODY></TABLE>
|
Posted by neshal
on 2004-08-02 07:05:52 |