方法一:
#include <>
#include<>
#include<>
#include<>
struct complex multiply(struct complex x, struct complex y);
struct complex{
int real;
int imag;
};
int main()
{
struct complex a,b,s;
scanf("%d%d%d%d",&);
s=multiply(a,b);
printf("(%d+%di)*(%d+%di)=%d+%di\n",);
return 0;
}
struct complex multiply(struct complex x, struct complex y)
{
struct complex m;
**;
**;
return m;
}
方法二:
#include<>
int main()
{
int a,b,c,d,e,f;
scanf("%d %d %d %d",&a,&b,&c,&d);
e = a * c - b * d;
f = a * d + b * c;
printf("(%d+%di)*(%d+%di)=%d+%di\n",a,b,c,d,e,f);
}