input: Write a function to create a class in Python that represents a complex number. The class should have an `__init__` method to initialize the real and imaginary parts of the complex number. It should also have a `__str__` method to return the complex number in the format "(real + imaginary i)".
  
  
  assert str(ComplexNumber(3, 4)) == "(3 + 4i)"
  assert str(ComplexNumber(-1, 2)) == "(-1 + 2i)"
  assert str(ComplexNumber(0, 0)) == "(0 + 0i)"
  assert str(ComplexNumber(5, -7)) == "(5 + -7i)"
  
output: class ComplexNumber:
      def __init__(self, real, imaginary):
          self.real = real
          self.imaginary = imaginary
  
      def __str__(self):
          return f"({self.real} + {self.imaginary}i)"