input: Write a python function to perform addition, subtraction, multiplication, and division on complex numbers using the Complex class.
  assert Complex(1, 2).add(Complex(3, 4)).real == 4
  assert Complex(1, 2).add(Complex(3, 4)).imaginary == 6
  assert Complex(5, 6).subtract(Complex(1, 2)).real == 4
  assert Complex(5, 6).subtract(Complex(1, 2)).imaginary == 4
  assert Complex(1, 1).multiply(Complex(1, -1)).real == 2
  assert Complex(1, 1).multiply(Complex(1, -1)).imaginary == 0
  assert Complex(4, 2).divide(Complex(2, 1)).real == 2
  assert Complex(4, 2).divide(Complex(2, 1)).imaginary == 0
output: class Complex:
      def __init__(self, real, imaginary):
          self.real = real
          self.imaginary = imaginary
  
      def add(self, other):
          return Complex(self.real + other.real, self.imaginary + other.imaginary)
  
      def subtract(self, other):
          return Complex(self.real - other.real, self.imaginary - other.imaginary)
  
      def multiply(self, other):
          real = self.real * other.real - self.imaginary * other.imaginary
          imaginary = self.real * other.imaginary + self.imaginary * other.real
          return Complex(real, imaginary)
  
      def divide(self, other):
          denom = other.real ** 2 + other.imaginary ** 2
          real = (self.real * other.real + self.imaginary * other.imaginary) / denom
          imaginary = (self.imaginary * other.real - self.real * other.imaginary) / denom
          return Complex(real, imaginary)