Let's call the number of $3 certificates A, 4 B, and 5, C.
To build $12 baskets, there are 3 ways, call them X, Y and Z:
X: A=0, B=2, C=1
Y: A=1, B=0, C=2
Z: A=3, B=1, C=0
So,
2X+Z<=13
3Z+Y<=13
2Y+X<=13
Subtracting the first from two times the third and multiplying by 3 yields
12Y-3Z<=39. Adding to the second equation yields
13Y<=52, or Y<=4.
Examining the second equation, the maximum Z could be is if Y=0, with Z therefore<=4.
Examining the third equation, the maximum X could be is if Y=0, with X<=6.
So, X<=6, Y<=4, Z<=4
Since X+Y+Z=12, let's try some values for Y since they are limited:
Y=0 means X+Z=12, not possible given above
Y=1 means X+Z=11, also not possible
Y=2 means X=6, Z=4 but these violate 2X+Z<=13 from before
Y=3 means X=6,Z=3 or X=5,Z=4, but either of these violate 2X+Z<=13 from before
Therefore, Y=4 and X+Z=8, which can be through 6,2;5,3 or 4,4
6,2 is excluded due to the 2X+Z limitation
Z=4 is eliminated since with Y=4, the 3Z+Y constraint is violated
So X=5,Y=4 and Z=3 is the only possibility remaining, which means 3 baskets with no $5 certificates
Posted from my mobile device