SOLUTION: How many different positive whole numbers less than 2018 contain only even digits

Algebra.Com
Question 1136762: How many different positive whole numbers less than 2018 contain only even digits
Found 2 solutions by Boreal, ikleyn:
Answer by Boreal(15235)   (Show Source): You can put this solution on YOUR website!
2008/2006/2004/2002/2000. Look for combinations of 8/6/4/2/0. After the first, there are 5 ways to choose the second and five ways to choose the third
888/886/884/882/880
868/866/864/862/860
...
808/806/804/802/800
25 ways for the 800s
25 ways for the 600s
(688/686/684/682/680...608/606/604/602/600/
25 ways for the 400s
25 ways for the 200s
and
25 ways for those <100 as well
130 of them
Alternatively, 5 ways to choose the first, the second, and the third (125) plus the other 5.

Answer by ikleyn(52908)   (Show Source): You can put this solution on YOUR website!
.

For simplicity, we can consider all these numbers as 4-digits numbers, by writing leading 0 (zero, or zeroes) to

all one-digit, two-digit and three-digit numbers.


We only need to subtract from this set the number  0 = "0000" at the end, since it is not positive number.


Now we can easy count all such numbers from 0 to 2000:

    fixed 0 in the most left position;

    any of 5 digits 0, 2, 4, 6, 8 in the hundreds position;

    any of 5 digits 0, 2, 4, 6, 8 in the tens position;

    any of 5 digits 0, 2, 4, 6, 8 in the ones position.


In all, there are  5*5*5 = 125 numbers, so far.


Subtract  "0000" from this set to get 125 - 1 = 124 numbers.


Add 6 numbers 2000, 2002, 2004, 2006, 2008, and you will find the final answer: 124 + 5 = 129 numbers.


ANSWER.  129 numbers.

Solved.


Notice that the answer  "130"  by  @Boreal is close to it,  BUT  NOT  EXACTLY  CORRECT :

            he forgot to subtract 0 = "0000" from the set.


RELATED QUESTIONS

How many numbers less than 9000 contain only 6, 7 or 8 as... (answered by KMST)
How many positive even integers of three different digits each are less than... (answered by Alan3354)
What is the sum of all the positive 3-digit whole numbers with even digits... (answered by robertb)
how many numbers of five different digits, each number to contain 3 odd and 2 even... (answered by stanbon)
how many numbers of five different digits, each number to contain 3 odd and 2 even... (answered by longjonsilver,303795)
How many positive integers are there less than 800 such that all digits are even? (answered by Alan3354,richard1234)
How many positive integers less than 600 have digits that are all... (answered by Alan3354)
How many whole numbers less than 500 have seven as the sum of their... (answered by ewatrrr)
how many positive whole numbers less than 100 are divisible by 3, but not by... (answered by Alan3354)