C-study/02-1/5/5.c

11 lines
214 B
C
Raw Normal View History

2021-09-29 07:15:39 +00:00
#include<stdio.h>
int main()
{
int a1,a2,b1,b2;
printf("Input a1,a2,b1,b2:");
scanf("%d %d %d %d",&a1,&a2,&b1,&b2);
printf("\n(%d+%di)*(%d+%di)=%d+%di",a1,a2,b1,b2,a1*b1-a2*b2,a1*b2+a2*b1);
return 0;
}