Bitwise Calculator

When values are treated as bits rather than a numerical value, it is termed as bitwise operation. These bits when moved left or right, is termed as bit shift. These shifts are of two types arithmetic shifts (bits that are shifted out at either ends are discarded) and logical shifts. Bit Shifts are sometimes considered as bitwise operations. In this bitwise calculator, find the binary and decimal value of a number when the bits are shifted to left or right.

Bit Shift Calculator

Code to add this calci to your website Expand embed code Minimize embed code

Formula:

Shift Left d = n * 2m Shift Right d = n / 2m Where, d = Decimal Value n = Input Decimal Number m = Number of Bits to Shift

Example

Consider a number 12.

Step 1 :

Find the binary value of 12.
The binary value of 12 is 1100.

Step 2 :

Applying Bitwise Shift
When shifted to 2 places in the right, the two 1's will be shifted as 0011.

Step 3 :

Find the decimal number of the binary value
Hence the decimal number of 0011 is 3.

english Calculators and Converters

Ask a Question