128. Arithmetic Edge Cases-II

Question.4

A developer uses right shift to divide a signed ADC offset by 2:

int8_t offset = -4;
int8_t halved = offset >> 1;
printf("%d", halved);

What does the C standard guarantee about the result?

Need Help? Refer to the Quick Guide below

Select Answer