input: Write a function that defines a class in Python to store and process data in a Car object. The class should have an initializer (__init__) method to set the make, model, color, and mileage of the car. It should also have two methods, accelerate and decelerate, to set the car's speed.
  
  
  class Car:
      def __init__(self, make, model, color, mileage):
          self.make = make
          self.model = model
          self.color = color
          self.mileage = mileage
  
      def accelerate(self, speed):
          self.speed = speed
  
      def decelerate(self, speed):
          self.speed = speed
  
  
  assert isinstance(Car("Toyota", "Camry", "Red", 50000), Car) == True
  assert hasattr(Car("Toyota", "Camry", "Red", 50000), "make") == True
  assert hasattr(Car("Toyota", "Camry", "Red", 50000), "accelerate") == True
  assert hasattr(Car("Toyota", "Camry", "Red", 50000), "decelerate") == True
output: class Car:
      def __init__(self, make, model, color, mileage):
          self.make = make
          self.model = model
          self.color = color
          self.mileage = mileage
          self.speed = 0
  
      def accelerate(self, speed):
          self.speed = speed
  
      def decelerate(self, speed):
          self.speed = speed