A probability problem by Ayush Jain

How many times do we write zeroes while listing integers from 1 to 3333?


The answer is 963.

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.

3 solutions

Ayush Jain
Oct 21, 2015

we first count all zeroes at ones place Therefore the number will be X0 where X can take values from 1 to 333 =333

Then we count the zeroes at tens place Therefore the number will be X0Y where X can take values from 1 to 33 & Y can take values from 0 to 9=10 i.e 33 x 10 = 330

Now we count the zeroes at hundreds place Therefore the number will be X0YZ where X can take values from 1 to 33=33, Y can take values from 0 to 9=10 & Z can take values from 0 to9=10 i.e 3x10x10=300

Total= 333+330+300=963

Xiaoying Qin
Oct 28, 2015

First use Java to make this code-

       public class asdjh{
          public static void main(String[] args){
               int a = 0;
               for(int i = 0;i<3333; i++){
                   a++;
                   System.out.print(a);
               }
           }
       }

Then, copy the string that comes out and paste onto word.

Finally, press Ctrl+F and for Replace, put 0 for find and whatever for the other, and click REPLACE ALL.

It should say "Word has made 963 \boxed{963} replacements."

That's the shortcut way to do it.

I think my way of applying excel is the easiest way among all posted here. But you have a simplest routine.

Lu Chee Ket - 5 years, 6 months ago
Ratul Pan
Oct 20, 2015

I have just counted and wrote......
1-99=9 zeroes
100-199=20 zeroes
200-299=20 zeroes
.
.
.
900-999=20 zeroes
Therefore, 1-999= 189 \boxed{189} zeroes
1000-1099=120 zeroes
1100-1999=180 zeroes
Therefore, 1000-1999= 300 \boxed{300} zeroes
Therefore, 2000-2999= 300 \boxed{300} zeroes
3000-3099=120 zeroes
3100-3333=54 zeroes
Therefore, 3000-3333= 174 \boxed{174} zeroes
Therefore, 1-3333= 963 \boxed{963} zeroes




0 pending reports

×

Problem Loading...

Note Loading...

Set Loading...