Edmund's Brainteasers
Problem 19
Solution
Problem 19: Even hymns. Solution.
Every second number is divisible by 2 to there are 542/2 = 271 divisible by 2. Every third number is divisible by 3 so 542/3 = 180 are divisible by 3. But the numbers divisible by 6 have been counted twice. There are 542/6 = 90 of these (every 6th number is divisible by 6). So there are 271+180-90 = 361 hymns divisible by either 2 or 3. Thus 542-361 = 181 hymn numbers are not divisible by 2 or by 3.