Here is the question:
A cookie recipe calls for the following ingredients:
- 1.5 cups of sugar
- 1 cup of butter
- 2.75 cups of flour
The recipe produces 48 cookies with this amount of the ingredients. Write a program that asks the user how many cookies he or she wants to make, and then displays the number of cups of each ingredient needed for the specified number of cookies.
I already saw the answer, and it only confused me more. I need someone to explain to me how we go about figuring out how many cups of sugar is needed if, for example, the user wants to bake 50 cookies.
EDIT: I'm mainly interested in the thought process used to solve the math portion of this problem.