#include
using namespace std;
struct math{double m;double n;};
int main(){
math a,b,c;
char d;
cout<<"请输入第一个复数的实部和虚部"<
cout<<"请输入第二个复数的实部和虚部"<
cout<<"请选择运算法则(+,-,*,/)"<
while(d!='+'&&d!='-'&&d!='*'&&d!='/')
{cout<<"输入错误!!!请重新输入"<
}
if(d=='+'){c.m=a.m+b.m; c.n=a.n+b.n;}
if(d=='-'){c.m=a.m-b.m;c.n=a.n-b.n;}
if(d=='*'){c.m=a.m*a.n-b.m*b.n;c.n=a.m*b.n+a.n*b.m;}
if(d=='/'){c.m=(a.m*b.m+a.n*b.n)/(b.m*b.m+b.n*b.n);
c.n=(a.n*b.m+a.m*b.n)/(b.m*b.m+b.n*b.n);}
cout<<"计算结果="<