How much would it cost to try every possible burger combination? I was at a restaurant that allows you to build your own custom burger. I got bored and started to work out how many possible combinations of burger there could be. After figuring that out and sharing the number with a friend he wondered how much it would cost you if you were to order every possible combination. This is where I got stuck.
Ignoring all the options that don't affect the price here's the basic menu:


*

*Choose either one (\$7.99) or two (\$9.48) patties.

*Choose from 7 cheeses \$0.89 each

*Choose from 10 hot toppings \$0.99 each

*Choose from 3 premium toppings \$1.49 each

*Choose from 4 cold toppings \$0.39 each


I've been mulling it over in my head for a few days and I can't really figure out a good way to go about it. The best thing I've come up with so far is to pick a category and find out the total to try all combinations in that category using $\sum _{i=1}^m \binom{m}{i} c i$ where $c$ is the cost per item and $m$ is the total number of items to choose from. Then taking that and multiplying it by all the other possibilities created by the other categories.
Please forgive me if I'm missing something obvious or screwed something up, my formal schooling doesn't extend much beyond algebra and that was a decade ago.
 A: Here's an alternative way to justify Thomas Andrews' calculation without appealing to averages:
Order all burgers in pairs containing one selection and its exact opposite. The total cost of each such pair is $$7.99 + 9.48 + 7\cdot 0.89 + 10\cdot 0.99 + 3\cdot 1.49 + 4\cdot 0.39 $$
To count the number of different pairs, identify each pair by its one-patty member. There are $2^{7+10+3+4}$ different one-patty burgers, so this is also the number of pairs.
A: The average cost of a burger is easy to compute - it will be $$\frac{(7.99+9.48)  + 7\cdot 0.89 + 10\cdot 0.99 + 3\cdot 1.49 + 4\cdot 0.39}2$$
The number of burgers is $2\cdot 2^7\cdot 2^{10}\cdot 2^3 \cdot 2^4$.
Now multiply.
Assuming you are allowed to choose "none" for the non-burger options.
A: So easy - too much work done above
$$2  \times   2^7  \times  2^{10}  \times   2^3  \times   2^4$$
Because except for the burger size (pick one or the other), you have to answer yes or no for each of the other add-ons, so $2^7$ means that you could have no cheese, one cheese, two cheeses, etc... up to $7$ cheeses... and so on.
Answer: $33,554,432$ ways
