Question 662008
Compute the number of four-digits integers whose digits are all odd or all even. 
<pre>
First we compute the number of four-digit numbers whose 
digits are all odd

There are 5 odd digits, 1,3,5,7,9.

We can choose the first odd digit 5 ways.
We can choose the second odd digit 5 ways.
We can choose the third odd digit 5 ways.
We can choose the fourth odd digit 5 ways.

That's 5·5·5·5 = 5<sup>4</sup> = 625 ways

Next we compute the number of four-digit numbers whose 
digits are all even

There are 5 even digits, 0,2,4,6,8. The difference 
between this and above is that 0 cannot be the first digit 
of a 4 digit number.

We can choose the first even digit only 4 ways, 
since it cannot be 0.

We can choose the second even digit 5 ways.
We can choose the third even digit 5 ways.
We can choose the fourth even digit 5 ways.

That's 4·5·5·5 = 4·5<sup>3</sup> = 500 ways.

So that's a total of 625+500 = 1125.

Edwin</pre>