How do you use food1.addBacon() ? im getting the error "Food object has no attribute 'addBacon'"
that should mean you have not defined addBacon() in your class definition. do you have def addBacon(self): in your class definition?
def addBacon(self):
no i did not, thank sm
got it thank u !
since the code was already submitted, i am just gonna give you the ode i used for it: def addBacon(self):
self.name = self.name + ' with bacon' self.price = self.price + 3 self.vegStatus = False