Explanation: Right shift of signed integers is undefined, and has implementation-defined behaviour. 5. Which of these expressions will make the rightmost set bit zero in an input integer x?
A. x = x | (x-1)
B. x = x & (x-1)
C. x = x | (x+1)
D. x = x & (x+1)
Answer:A
Explanation: Right shift of signed integers is undefined, and has implementation-defined behaviour. 5. Which of these expressions will make the rightmost set bit zero in an input integer x?
A. x = x | (x-1) B. x = x & (x-1) C. x = x | (x+1) D. x = x & (x+1)
Explanation: None. 6. Which of these expressions will isolate the rightmost set bit?