以下是引用虐尸专家在2012-10-23 00:42:53的发言:
# include <stdio.h>
int main(void)
{
int a;
int b;
scanf("%d %d", &a, &b);
int w=a+b;
int x=a-b;
int y=a*b;
int z=a/b;
printf("%d %d %d %d\n", w, x, y, z);
return 0;
}
# include <stdio.h>
int main(void)
{
int a,b,w,x,y,z;
scanf("%d %d", &a, &b);
printf("%d %d %d %d\n", w=a+b, x=a-b, y=a*b, z=a/b);
return 0;
}
两个都可以,楼主采纳。
# include <stdio.h>
int main(void)
{
int a;
int b;
scanf("%d %d", &a, &b);
int w=a+b;
int x=a-b;
int y=a*b;
int z=a/b;
printf("%d %d %d %d\n", w, x, y, z);
return 0;
}
# include <stdio.h>
int main(void)
{
int a,b,w,x,y,z;
scanf("%d %d", &a, &b);
printf("%d %d %d %d\n", w=a+b, x=a-b, y=a*b, z=a/b);
return 0;
}
两个都可以,楼主采纳。
后面输出语句中,直接上了四个赋值语句什么情况,可以这样用吗?