class Restaurant:
def init(self,restaurant_name,cuisine_type):
self.n=restaurant_name
self.ct=cuisine_type
def describe_restaurant(self):
print(f"name is {self.n}.")
print(f"cuisine type {self.ct}.")
def open_restaurant(self):
print("The restaurant is open.")
kfc=Restaurant(‘KFC’,‘fried chicken’) #创建一个实例
print(f"The restaurant name is {kfc.n}.“)#打印前述信息之一名字
print(f"The restaurant cuisine type is {kfc.ct}.”)#打印前述信息之二类型
kfc.describe_restaurant()
kfc.open_restaurant()