-
Write a constructor method for the class Car that sets
the following attributes
manufacturer
model
year
color
def __init__(self, manufacturer, model, year, color):
self.manufacturer = manufacturer
self.model = model
self.year = year
self.color = color
-
Write the method get_manufacturer that returns
the manufacturer.
def get_manufacturer(self): return self.manufacturer
-
Write the method get_model that returns
the model.
def get_model(self): return self.model
-
Write the method get_year that returns
the year.
def get_year(self): return self.year
-
Write the method get_color that returns
the color.
def get_color(self): return self.color
-
Write the method get_model_year
that returns the model and the year separated by a space.
def get_model_year(self): return self.model + " " + self.year