Question: [ Python ] Define a function called print _ menu that will print the daily menu. It should be reusable enough to print any of
Python Define a function called printmenu that will print the daily menu. It should be reusable enough to print any of daily menus when callednot just Monday's.
FIrst:
Only Monday Menu is defined so far. The menu of five cookieswill change daily.
mondaymenu choccy chipper': price: 'stock':
'fudgy pudgy': price: 'stock':
'key lime crime': price: 'stock':
'salty sailor': price: 'stock':
'blueberry blooper': price: 'stock':
Second:
We have created a for loop iterate over the mondaymenu dictionary to print each cookie and it's price.
for x y in mondaymenu.items:
printfx: $yprice
Third:
We are allowed to call today's date by enter the code:
datetime.date.today
What element from the above tasks did I have to modify for my function to be reusable across a variety of daily menus?
Step by Step Solution
There are 3 Steps involved in it
1 Expert Approved Answer
Step: 1 Unlock
Question Has Been Solved by an Expert!
Get step-by-step solutions from verified subject matter experts
Step: 2 Unlock
Step: 3 Unlock
