Can anyone explain the reason behind the situation below :
the following code :
unsigned int x,y;
x = 0xAAAAAAAA;
y = x >> 32;
Why is it that if I shift a 32 bit variable by 32 bits, I get the same number. If I shift a number, say :
y = 0xFFFFFFFF >> 32
then y=0. ????
if I let x=FFFFFFFF and then do:
y = X >> 31;
y = y >> 1;
THEN I get y=0, but not if I do all the shifting at once.