- This event has passed.
4:30pm – Python OOP – Roland
February 1 @ 4:30 pm - 5:30 pm
Today We Did
- Finished rest of Try it Yourself homework from last week (9-4 and 9-5)
- Created methods that set and increment number_served for Restaurant class
- Fixed bug with resetting amount of fails in User class
- Continued modifying GroceryShopping project to use classes and dictionaries
- Converted our string menu into a menu of LuxuryItem objects
- Made our menu print out by iterating through the dictionary
Homework
Continue working on the GroceryShopping project, try to make as much of it function with the menu dictionary. Add more fun functionality to it too if you want (like a total price counter, set amount of money a user starts out with .etc)
Before next class, at least have it print out “Thank you for buying (item_name)” when a user tries to buy a LuxuryItem that is in the menu
If you have any questions, feel free to email me at rolandyang@ayclogic.com