Find the sum of all 3 - digit natural numbers which contain at least one odd digit and at least one even digit .
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.
1.To start off, we find the sum of all 3-digit natural numbers. So, because there are 900 natural 3-digit numbers starting from 100 and ending at 999, the sum is (100+999) \times (900)/2 = 494550.
2.Next, we find the sum of all 3-digit natural numbers that have only odd digits. There are five possible numbers that are odd for digits of the number, so there are 5 \times 5 \times 5 = 125 3-digit numbers that only have odd digits, starting from 111 and ending at 999. The sum of those numbers is (111+999) \times (125)/2 = 69375.
3.Then, we find the sum of all 3-digit numbers that only have even digits. There are five possible even numbers. However, since the number has 3 digits, 0 cannot be the hundreds digit, so there are (5-1) \times 5 \times 5 = 100 3-digit numbers that have only even digits, starting from 200 and ending at 888. The sum of those numbers is (200+888) \times (100)/2 = 54400.
4.Finally, we take the total sum of all 3-digit numbers and subtract by the sums of 3-digits numbers that only have odd or even digits to get our desired sum: the sum of 3-digit numbers that have at least one odd digit and one even digit. So, 494550 - 69375 - 54400 = 370775 :)