The price is multiplied by the fraction: (number bought)/(number included in the price). The total amount spent is the sum of amounts spent on each item.
... (9/6)×$2 + (18/12)×$9 + (21/6)×$4 = $3 + 13.50 +14.00 = $30.50
5.8m questions
7.6m answers