有以下程序: #include <stdio.h> main( ) { char x=2,y=2,z; z=(y<<1)&(X>>1); printf("%d\n",z); } 程序的输出结果是
本题考查位运算<<、 &。 y<<1 为 4, x>>1 为 1, 二者“与” 操作后为 0,所以 B 选项正确。