#include <stdio.h>
int main()
{
unsigned x;
scanf("%u", &x);
int temp = *(short *)&x; //取x的低16位,存入temp中
x >>= 16; //x右移16位,让x的高位变成低位
temp <<= 16; //temp左移16位,让temp的低位变成高位
x |= temp; //x和temp二进制或
printf("%u\n", x);
return 0;
}
洛谷p1100记录
最新推荐文章于 2023-09-27 10:18:55 发布