Bob has 19 candy packs, each of which contains either 4 or 5 candies. His friend counts the total number of candies and tells Bob that it is a multiple of 17.
How many packs contain 5 candies?
This section requires Javascript.
You are seeing this because something didn't load right. We suggest you, (a) try
refreshing the page, (b) enabling javascript if it is disabled on your browser and,
finally, (c)
loading the
non-javascript version of this page
. We're sorry about the hassle.
Let x denote the number of 4 -piece packs and y the number of 5 -piece packs. The equations to solve are x + y 4 x + 5 y = 1 9 = 1 7 ℓ where ℓ is the positive integer. In m o d 1 7 , x + y 4 x + 5 y ≡ 2 ≡ 0 So y ≡ − 8 ≡ 9 five piece candy packs . So we have 1 0 four-piece and 9 five-piece packs as the only solution for the problem since 1 7 is prime.