Whenever Mother goes shopping she brings home half a dozen boxes of fancy cakes, invariably dividing her custom between B's Tea Rooms, S's Bakery
and P's Stores whose boxes contain 3, 4, and
5 cakes respectively.
During last month she made seven such expeditions and came home with a different number of cakes each time, 80 in all coming from P's Stores.
How many were provided by S's Bakery?
There are 28 ways of obtaining 6 boxes from 3 stores if one
is permitted to get zero boxes from some stores. For now, I will assume the intent is that at
least one box must be obtained from each store which lowers the number of ways
to 10.
Here are these 10 ways, sorted by total cakes. The slash marks indicate where there is a
duplication in the number of total cakes.
There are 3 such duplicates, so there are 7 groups.
B S P
#Cakes
4 1 1
21
3 2 1 22
2 3 1
23 \
3 1 2
23 /
1 4 1 24
\
2 2 2 24
/
1 3 2 25
\
2 1 3 25
/
1 2 3 26
1 1 4 27
We need to find a group of 7 ways such that the total in the
P column is 16 (because 16*5=80 cakes), and it turns out we have exactly 7
groups from which to choose.
By selecting the member of each group with the maximum
number of P boxes, we get:
1+1+2+2+3+3+4 = 16
and 16*5 = 80 cakes of type “P”.
We want the number of cakes of type “S”, so add the
corresponding values from the S column:
1+2+1+2+1+2+1 = 10 and 10*4 = 40 cakes of type “S”.
So, IF Mother always buys at least one box from each store,
then there were 40 cakes from S's Bakery.

Posted by Larry
on 20170901 12:13:48 