public class complex3
{ public double real;
  public double imaginary;
  
  public complex3(double g,double s)
  {real=g;
   imaginary=s;
  }
  
  public  static complex3 add(complex3 s1,complex3 s2)
  {kompleks_sayi3 z3=new complex33((s1.gercek+s2.gercek),(s1.sanal+s2.sanal));
   return z3;
  }
  
  public void add(complex3 s1)
  {real+=s1.real;
   imaginary+=s1.imaginary;
  }
   
  public String toString()
  { String s="complex number = "+real+" + i*"+imaginary+" \n";
    return s;
  }
    
}