Binary to Decimal Conversion - Bitwise Right shift Operator
It is number system conversion from binary (base -2) to decimal (base -10) is carried out by bitwise >> (right-shift) operator. The Right shift operator moves the bit position of a integer towards right direction. it removes bits from LSB (least significant bit) and add bits (0s) into MSB (least significant bit) and the number bits to remove and to add depends on a operand value next to the right shift operator. For example, the integer variable x=74 , move 2 bit using right-shift operator binary 8-bits of x = 01001010 x = x >> 2 move 2 bit (remove two bits from LSB (10) and add two bits (00) into MSB 2-bits shifted binary 8-bits of x = 00010010 and x's decimal value becomes 18. Binary to decimal conversion using Bitwise Right-shift...