Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

Really need help with the codes! It's python 3. Thanks. Expected output (second example on next page, user input in How many cupcakes do you

image text in transcribed

Really need help with the codes!

It's python 3.

Thanks.

Expected output (second example on next page, user input in How many cupcakes do you want to make? 12 100.0 grams flour 100.0 grams sugar 100.0 grams butter 2.0 eggs 1.0 teaspoons vanilla 1.0 teaspoons baking powder Now, in cups! 0.83 cups flour 0.5 cups sugar 0.42 cups butter 2.0 eggs 1.0 teaspoons vanilla 1.0 teaspoons baking powder How many cupcakes do you want to make? I 8.33 grams flour 8.33 grams sugar 8.33 grams butter 0.17 eggs 0.08 teaspoons vanil1la 0.08 teaspoons baking powder Now, in cups! 0.07 cups flour 0.04 cups sugar 0.03 cups butter 0.17 eggs 0.08 teaspoons vanilla 0.08 teaspoons baking powder Development Your code should always be in a "runnable" state. Do not attempt to develop vour entire program without runnina it, Follow each step given below and test your code before moving to the next step 1) Write your main () function, where you will ask the user how many cupcakes they want to make and calculate the "recipe multiplier". Don't forget to call your main function! a) Your "recipe multiplier" will be 1 if the user is making 12 cupcakes, 2 if they are making 24, 0833333333 if they are making 1 cupcake, etc 2) Write a function to calculate an ingredient amount that is adjusted by the number of recipes ("recipe multiplier") you are making. This function should return this new, adjusted value rounded to the nearest 100ths place a) This function takes two parameters, your "recipe multiplier", and the original amount of this ingredient needed for this recipe i For example, when making 1 cupcake and calculating the adjusted amount of flour, this function would be passed the values. 0833333333 and 100. 3) Calculate the adjusted ingredient amounts for all your ingredients by calling your function from step #2 in your main() function. Don't forget to save the return values

Step by Step Solution

There are 3 Steps involved in it

Step: 1

blur-text-image

Get Instant Access to Expert-Tailored Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image

Step: 3

blur-text-image

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Recommended Textbook for

Optimizing Data Collection In Warzones

Authors: Aaget Aamber

1st Edition

B0CQRRFP5F, 979-8869065902

More Books

Students also viewed these Databases questions

Question

LO3 Describe the two most common methods of applying for a job.

Answered: 1 week ago