What argument 'isinstance' takes on declaring 'k' object?

前端 未结 0 1417
眼角桃花
眼角桃花 2021-01-31 07:10
class Point:
    def __init__(self, x_or_obj = 0, y = 0):
        if isinstance(x_or_obj, Point):
            self.x = x_or_obj.x
            self.y = x_or_obj.y
                


        
相关标签:
回答
  • 消灭零回复
提交回复
热议问题