//Myclass.h
#include<iostream.h>
#include<iomanip.h>
class Complex
{
double real,imag;
public:
Complex(){real=0;imag=0;}
Complex(double r){real=r;imag=0;}
Complex(double r,double i){real=r;imag=i;}
Complex operator +(const Complex &second);
double getreal(){return real;}
double getimag(){return imag;}
};
Complex Complex::operator +(const Complex &second)
{
double r,i;
r=real+second.real;
i=imag+second.imag;
return Complex(r,i);
}
[求助](双目运算符)解释一段代码