python | February 09, 2020
attribute(속성); 명사
method; 동사
class Car:
def __init__(self, model, color): #attribute
self.model = model
self.color = color
def honk(self): #method
return "빵빵"
car1 = Car("model_name", "yellow")
car1.honk()