document.write( "Question 671026: Find the number of positive integers less than 1000 that contains at least one odd digit and at least one even digit. \n" ); document.write( "
Algebra.Com's Answer #417254 by AnlytcPhil(1810)\"\" \"About 
You can put this solution on YOUR website!
\r\n" );
document.write( "To contain at least one odd digit and at least one even digit, \r\n" );
document.write( "and be less than 1000, a counting integer must have two or three \r\n" );
document.write( "digits.\r\n" );
document.write( "\r\n" );
document.write( "Two digit counting numbers:\r\n" );
document.write( "\r\n" );
document.write( "There are 90 2-digit numbers altogether, because there are \r\n" );
document.write( "9 ways to choose the first digit and 10 ways to choose the \r\n" );
document.write( "second digit, and 9×10 = 90\r\n" );
document.write( "\r\n" );
document.write( "From that 90 we must subtract the number of two-digit numbers\r\n" );
document.write( "with two even digits. There are 4 ways to choose the first\r\n" );
document.write( "even digit and 5 ways to choose the second even digit, That's\r\n" );
document.write( "4×5 or 20 two-digit numbers with both even digits we must subtract\r\n" );
document.write( "from the 90.  That makes 90-20 or 70\r\n" );
document.write( "\r\n" );
document.write( "From that 70 we must subtract the number of two-digit numbers\r\n" );
document.write( "with two odd digits. There are 6 ways to choose the first\r\n" );
document.write( "odd digit and 5 ways to choose the second odd digit, That's\r\n" );
document.write( "5×5 or 25 two-digit numbers with both odd digits we must subtract\r\n" );
document.write( "from the 70.  That makes 70-25 or 45.\r\n" );
document.write( "\r\n" );
document.write( "So there are 45 2-digit numbers that have one even and one odd digit.\r\n" );
document.write( "\r\n" );
document.write( "   \r\n" );
document.write( "Three digit counting numbers:\r\n" );
document.write( "\r\n" );
document.write( "There are 900 three-digit numbers altogether, because there are 9 \r\n" );
document.write( "ways to choose the first digit, 10 ways to choose the second digit, \r\n" );
document.write( "and 10 ways to choose the third digit. \r\n" );
document.write( "That makes 9×10×10 = 900\r\n" );
document.write( "\r\n" );
document.write( "From that 900 we must subtract the number of three-digit numbers\r\n" );
document.write( "with all even digits. There are 4 ways to choose the first even \r\n" );
document.write( "digit, 5 ways to choose the second even digit, and 5 ways to\r\n" );
document.write( "choose the third even digit. That's 4×5×5 or 100 three-digit \r\n" );
document.write( "numbers with all even digits which we must subtract from the 900.\r\n" );
document.write( "That makes 900-100 or 800.\r\n" );
document.write( "\r\n" );
document.write( "From that 800 we must subtract the number of three-digit numbers\r\n" );
document.write( "with all odd digits. There are 5 ways to choose the first odd \r\n" );
document.write( "digit, 5 ways to choose the second odd digit, and 5 ways to\r\n" );
document.write( "choose the third odd digit. That's 5×5×5 or 125 three-digit \r\n" );
document.write( "numbers with all odd digits which we must subtract from the 800.\r\n" );
document.write( "That makes 800-125 or 675.\r\n" );
document.write( "\r\n" );
document.write( "So there are 675 3-digit numbers that contain at least one odd \r\n" );
document.write( "digit and at least one even digit.\r\n" );
document.write( "\r\n" );
document.write( "So 45 two-digit numbers plus 675 three-digit numbers = 720. \r\n" );
document.write( "\r\n" );
document.write( "Answer: 720.\r\n" );
document.write( "\r\n" );
document.write( "Edwin

\n" ); document.write( "
\n" ); document.write( "
\n" );