Probability an integer chosen at random from 1 to 1000 is divisible by 3,5, or 7 A number is chosen at random from the first 1,000 positive integers. What is the probability that it's divisible by 3,5, or 7? 
So I started off by breaking the problem up and having:
divisible by 3: p(a)
divisible by 5: p(b)
divisible by 7 p(c)  
I know I'm going to apply the exclusion inclusion principle, but how do I find out how many numbers are divisible by each without going through all the numbers between 1 and 1000?
 A: Hint The largest multiple of $3$ in $\{1, \ldots, 1000\}$ is $3 \lfloor \tfrac{1000}{3} \rfloor = 3 \cdot 333 = 999$ and so there are $\lfloor \frac{1000}{3} \rfloor = 333$ mutiples of $3$ in that range. Similarly, there are $\lfloor \frac{1000}{5} \rfloor = 200$ multiples of $5$, and there are $\lfloor \frac{1000}{15} \rfloor = 66$ multiples of $3 \cdot 5 = 15$.
A: From Excel 
=INT(1000/3)+INT(1000/5)+INT(1000/7)-INT(1000/15)-INT(1000/21)-INT(1000/35)+INT(1000/105)=543
p=0.543
A: Use inclusion/exclusion principle:


*

*Include the amount of numbers divisible by $3$, which is $\Big\lfloor\frac{1000}{3}\Big\rfloor=333$

*Include the amount of numbers divisible by $5$, which is $\Big\lfloor\frac{1000}{5}\Big\rfloor=200$

*Include the amount of numbers divisible by $7$, which is $\Big\lfloor\frac{1000}{7}\Big\rfloor=142$

*Exclude the amount of numbers divisible by $3$ and $5$, which is $\Big\lfloor\frac{1000}{3\cdot5}\Big\rfloor=66$

*Exclude the amount of numbers divisible by $3$ and $7$, which is $\Big\lfloor\frac{1000}{3\cdot7}\Big\rfloor=47$

*Exclude the amount of numbers divisible by $5$ and $7$, which is $\Big\lfloor\frac{1000}{5\cdot7}\Big\rfloor=28$

*Include the amount of numbers divisible by $3$ and $5$ and $7$, which is $\Big\lfloor\frac{1000}{3\cdot5\cdot7}\Big\rfloor=9$


Hence the amount of numbers divisible by $3$ or $5$ or $7$ is:
$$333+200+142-66-47-28+9=543$$
