American Young Coder

AYC logo
Loading Events

« All Events

  • This event has passed.

6:00 PM – Python OOP- Joshua

August 7 @ 6:00 pm - 7:00 pm

Today we did

  • practice dictionaries
  • practiced application loops
  • practiced our if statements with dictionaries to check for valid slection

 

Homework

Add these two functions

def calculate_price(self):
    # move the price calculation stuff over and make sure it works.
    pass


def print_menu(self):
    # I don 't like that we have a big blob of text as our menu
    # What if we had 20000 thing in our dictionary
    # Our goal is to have this method print out our menu
    #Step 1 print the first line of the menu ("What do you want to purchase:")
    #Step 2 with for loop, use the dictionary to "print" out the options
    # Example f" {<insert key here>}. {<Insert Item name>} -  {<insert price>}"
    #Step 3 after the for loop print a Exit option ("Use exit instead of 4")


    pass

Details

Date:
August 7
Time:
6:00 pm - 7:00 pm