MFC改变对话框控件字体

C语言不创建中间变量交换2个数

赵4老师: [code=csharp] #include <stdio.h> #define SWAP(a,b) do ((&(a))!=(&(b)))?((a)^=(b)^=(a)^=(b)):((a)=(a)); while (0) char *p1="1" ,*p2="2" ; char c1=1 , c2=2 ; short s1=1 , s2=2 ; int i1=1 , i2=2 ; __int64 I1=1i64, I2=2i64; float f1=1.0f, f2=2.0f; double d1=1.0 , d2=2.0 ; void main() { SWAP((int)p1,(int)p2); printf("char * %5s, %5s\n",p1,p2); SWAP(c1,c2); printf("char %5d, %5d\n",c1,c2); SWAP(s1,s2); printf("short %5d, %5d\n",s1,s2); SWAP(i1,i2); printf("int %5d, %5d\n",i1,i2); SWAP(I1,I2); printf("__int64 %5I64d,%5I64d\n",I1,I2); SWAP(*(int *)&f1,*(int *)&f2);printf("float %5g, %5g\n",f1,f2); SWAP(*(__int64 *)&d1,*(__int64 *)&d2);printf("double %5lg, %5lg\n",d1,d2); SWAP(c1,c1); printf("%d\n",c1); } [/code]

上一篇:基于STM32的火灾烟雾报警器Proteus仿真设计(仿真+程序+设计报告+讲解视频)-4. 设计报告