You can put this solution on YOUR website! For the first digit, you have the choice of values 0-9, but you can't have the value 5 or 0 (since numbers don't have zeros on the left most side). So this means that you have 8 choices for the first digit. For the other digits (the 5 remaining digits), you have 9 choices. Simply multiply all these possibilities to get
So there are 472,392 six digit numbers that do NOT have a 5 anywhere in the number.