异或实现了交换
void swap(int a, int b) { //int a =2, b=6; a = a ^ b; b = b ^ a; a = a ^ b; printf("a=%d, b=%d \n", a, b); }
Last updated 7 months ago