#include <stdio.h>
int main()
{
int x,y;
x = 10;
y = -3;
printf("x+y=%d\n",x,y );
printf("x-y=%d\n",x,y );
printf("x*y=%d\n",x,y );
printf("x/y=%d\n",x,y );
printf("x%%y=%d\n",x,y );
return 0;
}
printf("x+y=%d\n",x,y ); 这里边只需要一个变量值 %d, 但是你在后边给传了两个x,y 应该写成 x+y
#include <stdio.h>
int main()
{
int x,y;
x = 10;
y = -3;
printf("x+y=%d\n",x+y );
printf("x-y=%d\n",x-y );
printf("x*y=%d\n",x*y );
printf("x/y=%d\n",x/y );
printf("x%%y=%d\n",x%y );
return 0;
}