Can we use bitwise operators on negative numbers.
Bitwise operators and negative numbers
right shift operator is not genarating correct expected output with negative numbers
bhaiya but when we right shift negative number it should produce positive one as sign bit get filled with 0.
hi @ritikbunty2511_729d0258992e0982 read here https://www.codespeedy.com/right-shift-negative-numbers-in-cpp/, msb is fixed