Maths WorkshopMaths problems with full solutions
Exercise 1003Combinatorics › Inclusion-exclusionL1Added 3 Nov 2026

Counting with divisibility

#IE#divisibility#counting

Statement

How many integers from 11 to 10001000 are divisible by 22, 33, or 55?

Hint

IE with floor functions.

Show solutionHide solution

Solution

Sets. ∣A2∣=⌊1000/2⌋=500|A_2|=\lfloor1000/2\rfloor=500, ∣A3∣=333|A_3|=333, ∣A5∣=200|A_5|=200.

Pairs. ∣A2∩A3∣=⌊1000/6⌋=166|A_2\cap A_3|=\lfloor1000/6\rfloor=166, ∣A2∩A5∣=100|A_2\cap A_5|=100, ∣A3∩A5∣=66|A_3\cap A_5|=66.

Triple. ∣A2∩A3∩A5∣=⌊1000/30⌋=33|A_2\cap A_3\cap A_5|=\lfloor1000/30\rfloor=33.

IE. 500+333+200−166−100−66+33=734500+333+200-166-100-66+33=734.

Conclusion. 734734 integers.