Question: can you guys please help me create this C++ code Write a program that produces a cookie recipe, adjusted to produce the desired number of
Write a program that produces a cookie recipe, adjusted to produce the desired number of cookies. The program should read the original recipe and the number of cookies produced by the original recipe from a file. Adjust the recipe to create the modified cookie recipe and produce an output file named recipeOut.txt with the adjusted recipe. Your program should use the function adjustIngredient and printIngredient. The function prototypes are provided below. The contents of the input file, named inData.txt, and a sample of the output file, named recipeOut.txt, are also provided below. Function Prototypes: - double adiustingredient (double, int, int) - void printingredient(double, string) inData.txt: Produced 48 sugar 1.5 butter 1.0 flour 2.75 outData.txt: Ingredients Needed: - 0.75 cups of sugar - 0.50 cups of butter - 1.38 cups of flour Cookies Produced: 24 conkies
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
