Hi everyone, I'm having a hard time with this problem:(adsbygoogle = window.adsbygoogle || []).push({});

Of the integers from 1000 to 9999, how many have at least one digit a 5 or 7?

My working :

[1000, 9999] = 9000 outcomes

∴ 9000 possible outcomes

Desired outcomes : (2*8^3) + (2^2*8^2)+(2^3*8)+(2^4), since 5 or 7 = 2 choices, any other numbers = 8 choices (from 0 - 9)

∴ 1360*4 desired outcomes (there are 4 places, and order matters here) = 5440 desired outcomes

But the textbook answers say 5416.

I was thinking :

maybe I should subtract from 5440 all desired outcomes which have a leading '0':

(1*8*8)+(1*2*8)+(1*2*2) = 84

∴ 5440 - 84 = 5356 (wrong!)

I'm not going to try and do numbers that have 2 leading '0's or more since the first is already proven that the answer is wrong.

Really confused about what I'm doing.

Any help would be very appreciated!

Thanks

Steve

**Physics Forums | Science Articles, Homework Help, Discussion**

Dismiss Notice

Join Physics Forums Today!

The friendliest, high quality science and math community on the planet! Everyone who loves science is here!

The friendliest, high quality science and math community on the planet! Everyone who loves science is here!

# Help with probability question

**Physics Forums | Science Articles, Homework Help, Discussion**