Answer:
First, let's determine how many cakes Mary needs to supply for an order worth 500,000 shillings.
Each cake is sold at 500 shillings:
\[ \text{Number of cakes} = \frac{500,000}{500} = 1,000 \text{ cakes} \]
Next, let's calculate how much sugar and flour are needed to make 1,000 cakes.
From the recipe:
50 cakes require 1 kg of sugar and 2 kg of flour.
So, for 1,000 cakes:
\[ \text{Sugar needed} = \frac{1,000 \text{ cakes}}{50 \text{ cakes}} \times 1 \text{ kg} = 20 \text{ kg of sugar} \]
\[ \text{Flour needed} = \frac{1,000 \text{ cakes}}{50 \text{ cakes}} \times 2 \text{ kg} = 40 \text{ kg of flour} \]
Now, let's calculate the cost of the ingredients:
Cost of sugar:
\[ 20 \text{ kg} \times 4,500 \text{ shs/kg} = 90,000 \text{ shillings} \]
Cost of flour:
\[ 40 \text{ kg} \times 4,000 \text{ shs/kg} = 160,000 \text{ shillings} \]
Total cost of ingredients:
\[ 90,000 \text{ shillings} + 160,000 \text{ shillings} = 250,000 \text{ shillings} \]
So, Mary is going to spend **250,000 shillings** on the ingredients.