38. Bitwise Rotation and Counting-I

Question.2

A developer implements an 8-bit left rotation:

uint8_t reg = 0xC5;
uint8_t result = (reg << 3) | (reg >> 5);

He expects 0x2E. Does this code produce the correct result?

Need Help? Refer to the Quick Guide below

Select Answer