#include<stdio.h>
#define TRUE 1
#define FALSE 0
#define PQ(x,y) x*x+y*y
int num1=1,num2,num3;
void fun1(){
int num1=1;
static int num2=2;
num3+=num1+num2++;
printf("in fun1() num1=%d,num2=%d,num3=%d\n",num1,num2,num3);
}
void main(){
num3+=(num2++)-(--num1);
printf("in main() num1=%d,num2=%d,num3=%d\n",num1,num2,num3);
num1=num2=num3=TRUE;
fun1();
num1=num2=num3=FALSE;
fun1();
#ifdef FALSE
num1=1; num2=2;
num3=PQ(num1+num2,num1-num2);
#else
num1=3; num2=4;
num3=PQ(num1,num2);
#endif
printf("in main() num1=%d,num2=%d,num3=%d\n",num1,num2,num3);
}
饮歌长啸
相关分类