input: Write a function to create a class in Python to store and process data in a Car object. The class should have an initializer to initialize attributes like make, model, color, and mileage. It should also have methods to simulate acceleration and deceleration.
  
  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 Car('Toyota', 'Camry', 'Red', 50000).make=='Toyota'
  assert Car('Honda', 'Accord', 'Blue', 30000).model=='Accord'
  assert Car('Ford', 'Mustang', 'Black', 20000).color=='Black'
  assert Car('Tesla', 'Model S', 'White', 10000).mileage==10000
output: 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