Jonathan C. answered 02/09/17
Tutor
New to Wyzant
Experienced General Mathematics Tutor
I will be using a trick very similar to what you would see in probability class:
The number of integers divisible by 2 from 1 to 1000 is 1000/2 = 500.
The number of integers divisible by 5 from 1 to 1000 is 1000/5 = 200.
The number of integers divisible by 2 AND 5 from 1 to 1000 is 1000/lcm(2,5) = 1000/10 = 100.
The number of integers divisible by 2 OR 5 from 1 to 1000 is 500 + 200 - 100 = 600. <-- union minus intersection from probability
The number of integers divisible by NEITHER 2 NOR 5 from 1 to 1000 is 1000 - 600 = 400. <-- complement from probability
So your answer is 400 integers.
These integers are the numbers ending in 1, 3, 7, and 9 (just in case you are curious).