a certain type of candy is sold in small boxes of 8 and large boxes of 15. notice it would be impossible to buy exactly 12 candies without breaking up a box. it would also be impossible to buy 17 candies without breaking up a box. what is the greatest number of candies that it would be impossible to buy without breaking up a box

10963458

To solve this problem, we need to find the greatest number that cannot be expressed as the sum of a multiple of 8 and a multiple of 15. This is known as the "Frobenius Coin Problem" or "Frobenius Number".

One approach to solve this problem is by using the Chicken McNugget theorem, also known as the Postage Stamp Problem. According to this theorem, given two coprime numbers (numbers without any common factors), m and n, the greatest number that cannot be expressed as the sum of a multiple of m and a multiple of n is (m * n) - (m + n).

In this case, the two numbers are 8 and 15. Calculating using the formula, we get: (8 * 15) - (8 + 15) = 120 - 23 = 97.

Therefore, the greatest number of candies that cannot be bought without breaking up a box is 97.