Class2 HTML : HTML Attribute HTML's Attribute : Description Attribute Description alt Specifies an alternative text for an image, when the image cannot be displayed disabled Specifies that an input element should be disabled href Specifies the URL (web address) for a link id Specifies a unique id for an element class Specifies a unique class for an element src Specifies the URL (web address) for an image style Specifies an .. 2020. 5. 10. Python : inheritance, 상속 : 부모 class 자식 class class father(): # 부모 클래스 def __init__(self, who): self.who = who def handsome(self): print("{}를 닮아 잘생겼다".format(self.who)) class sister(father): # 자식클래스(부모클래스) 아빠매소드를 상속받겠다 def __init__(self, who, where): super().__init__(who) self.where = where def choice(self): print("{} 말이야".format(self.where)) def handsome(self): super().handsome() self.choice() girl = sister("아빠", "얼굴") girl.handsome() 출처: .. 2020. 4. 21. 이전 1 다음