大神,帮我看一下这个程序,看不太懂
# include <stdio.h># define MAX(a,b) (a)>(b)?(a):(b)
# define SQUARE(x) x*x
# define DOUBLE(x) x+x
int main()
{
int x,y,z;
y=2;
z=3;
x=MAX(y,z);
printf("%d %d %d\n",x,y,z);
y=2;
z=3;
x=MAX(++y,++z);
printf("%d %d %d\n",x,y,z);
x=2;
y=SQUARE(x);
z=SQUARE(x+6);
printf("%d %d %d\n",x,y,z);
x=2;
y=3;
z=MAX(5*DOUBLE(x),++y);
printf("%d %d %d\n",x,y,z);
return 0;
}
输出结果是这样的:
3 2 3
5 3 5 //不明白为什么是这个结果,求解答
2 4 20 //这个也不懂
2 4 12 //这个也不懂
Press any key to continue