Quantcast Intermediate How Many Ones? - XP Math - Forums
XP Math Home Sign Up FREE! | Sign In | Classroom Setup | Common Core Alignment PDF Version

Go Back   XP Math - Forums > Mathematics > Math Challenges

Reply
 
Thread Tools Display Modes
Old 03-24-2009   #1
MAS1

Points: 8,254, Level: 61
Points: 8,254, Level: 61 Points: 8,254, Level: 61 Points: 8,254, Level: 61
Activity: 33.3%
Activity: 33.3% Activity: 33.3% Activity: 33.3%
Last Achievements
 
Join Date: Dec 2008
Posts: 249
Default How Many Ones?

How many times does the digit 1 appear in all the whole numbers between 0 and 999,999? For example 1 appears 3 times in the number 1,101 and 2 times in 101,058.
MAS1 is offline   Reply With Quote
Old 03-25-2009   #2
Mr. Hui


Last Achievements
 
Mr. Hui's Avatar
 
Join Date: Mar 2005
Posts: 10,647
Default

This is an interesting problem. My first thought is looking at every place value and calculating how many times "1" can possibly appear. I'm sure there's a variety of strategies.
__________________
Do Math and you can do Anything!
Mr. Hui is offline   Reply With Quote
Old 03-27-2009   #3
Yiwan
 
Yiwan's Avatar
 
Join Date: Mar 2009
Posts: 48
Default



This kind of challenges make the people think........

I will try to find the answer.
Yiwan is offline   Reply With Quote
Old 04-20-2009   #4
Sugengz
 
Join Date: Mar 2009
Posts: 4
Default

Using Mathematica the answer is 600,000...

Here is the code:

For[x = 1; y = 0, x <= 999999, x++; y = y + StringCount[ToString[x], "1"]]; Print[y]
Sugengz is offline   Reply With Quote
Old 04-20-2009   #5
MAS1

Points: 8,254, Level: 61
Points: 8,254, Level: 61 Points: 8,254, Level: 61 Points: 8,254, Level: 61
Activity: 33.3%
Activity: 33.3% Activity: 33.3% Activity: 33.3%
Last Achievements
 
Join Date: Dec 2008
Posts: 249
Default

Quote:
Originally Posted by Sugengz View Post
Using Mathematica the answer is 600,000...

Here is the code:

For[x = 1; y = 0, x <= 999999, x++; y = y + StringCount[ToString[x], "1"]]; Print[y]
Yes.
There are 1,000,000 numbers between 0 and 999,999.
We can think of each of these numbers as having six digits whether 000,001 or 999,973.
So if there are 1 million numbers with six digits each then there are six million total digits.
Since we are going from 000,000 to 999,999 and there are ten digits (0,1,2,,8,9), then each digit is used the same number of times.
So there must be 6,000,000 / 10 = 600,000 of each digit used
Therefore, there are 600,000 1s between 0 and 999,999.

Also, there are:
1 "1" between 0 and 9
20 "1's" between 0 and 99
300 "1's" between 0 and 999
4,000 "1's" between 0 and 9,999
50,000 "1's" between 0 and 99,999
600,000 "1's" between 0 and 999,999
etc
MAS1 is offline   Reply With Quote
Old 05-01-2009   #6
weepa
Last Achievements
 
weepa's Avatar
 
Join Date: Apr 2009
Posts: 5
Default

That's cool, I couldn't figure it out.
weepa is offline   Reply With Quote
Old 02-04-2010   #7
twlightfan152
 
twlightfan152's Avatar
 
Join Date: Feb 2010
Posts: 1
Angry

hello im new to xp math:
twlightfan152 is offline   Reply With Quote
Old 02-20-2010   #8
jmw106462

Last Achievements
 
jmw106462's Avatar
 
Join Date: Feb 2010
Posts: 388
Default

904 times idk?
jmw106462 is offline   Reply With Quote
Old 08-20-2010   #9
pineapple74
Points: 8,613, Level: 62
Points: 8,613, Level: 62 Points: 8,613, Level: 62 Points: 8,613, Level: 62
Activity: 0%
Activity: 0% Activity: 0% Activity: 0%
Last Achievements
 
pineapple74's Avatar
 
Join Date: May 2010
Posts: 60
Default I like that

Quote:
Originally Posted by MAS1 View Post
Yes.
There are 1,000,000 numbers between 0 and 999,999.
We can think of each of these numbers as having six digits whether 000,001 or 999,973.
So if there are 1 million numbers with six digits each then there are six million total digits.
Since we are going from 000,000 to 999,999 and there are ten digits (0,1,2,,8,9), then each digit is used the same number of times.
So there must be 6,000,000 / 10 = 600,000 of each digit used
Therefore, there are 600,000 1s between 0 and 999,999.

Also, there are:
1 "1" between 0 and 9
20 "1's" between 0 and 99
300 "1's" between 0 and 999
4,000 "1's" between 0 and 9,999
50,000 "1's" between 0 and 99,999
600,000 "1's" between 0 and 999,999
etc
Like that And will remember that.
__________________
Nothing is impossible
pineapple74 is offline   Reply With Quote
Old 09-03-2010   #10
court4298
Points: 4,922, Level: 44
Points: 4,922, Level: 44 Points: 4,922, Level: 44 Points: 4,922, Level: 44
Activity: 0%
Activity: 0% Activity: 0% Activity: 0%
Last Achievements
 
court4298's Avatar
 
Join Date: Sep 2010
Posts: 3
Default

Quote:
Originally Posted by Sugengz View Post
Using Mathematica the answer is 600,000...

Here is the code:

For[x = 1; y = 0, x <= 999999, x++; y = y + StringCount[ToString[x], "1"]]; Print[y]
thanks i needed help
court4298 is offline   Reply With Quote
Reply

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT -4. The time now is 09:56 PM.


Powered by vBulletin® Version 3.8.11
Copyright ©2000 - 2017, vBulletin Solutions Inc.
XP Math