题目内容
There is an error when running the following codes,NameError: name 'r' is not defined. Please correct the error.下列代码运行时错误提示NameError: name 'r' is not defined,请改正其中的错误。import mathclass Circle:def __init__(self, r):self.r = rdef area(self):return math.pi*r*rc = Circle(2)print(c.area())
查看答案
搜索结果不匹配?点我反馈