class Restaurant():
def __init__(self, name, type):
self.name = name
self.type = type
self.number_served = 0
def describe_restaurant(self):
print('this restaurant name :' + self.name)
print('this is a '+ self.type + ' restaurant')
def open_restaurant(self):
print('The restaurant is opening')
def restaurant_served(self):
print(str(self.number_served))
new_restaurant = Restaurant('juli','kuaishu')
new_restaurant.describe_restaurant()
new_restaurant.open_restaurant()
new_restaurant.restuarant_served()
错误类型:'Restaurant' object has no attribute 'restuarant_served'
为什么