Why this snap of code prints -64? I'm not sure that I understand the shifting right, but it seems odd.
char t = 0x80;
printf("%i", t); //print -128 => 0b10000000
printf("%i", t>>1); //print -64 => 0b11000000, not 0b01000000
Why this snap of code prints -64? I'm not sure that I understand the shifting right, but it seems odd.
char t = 0x80;
printf("%i", t); //print -128 => 0b10000000
printf("%i", t>>1); //print -64 => 0b11000000, not 0b01000000