新手上路,求大佬指点
class Dog():"""模拟"""
def__init__(self, name, age):
"""初始"""
self.name = name
self.age = age
def sit(self):
"""action_1"""
print(self.name .title() + ' is now sitting.')
def roll_over(self):
"""action_2"""
print(self.name.title() + ' rolled over!')
为什么会显示无效语法?