hi,
Can anyone explain.....how the compiler computes the output for this ????
insertaccording to me....-1 is represented asCode:int main() { printf("%x\n",-1>>4); }
1000 0000 0000 0000 0000 0000 0000 0001
High order bits lower order bits
I am using microsoft VC++ compiler so int occupies 4 bytes.
so when u right shift by 4 it should display 0.
But it displays ffff....
Can anyone explain how.....????
Regards,
Rohit