Conversions - Binary and Hexadecimal
 

Binary to Hex Conversion
It is easy to convert from an integer binary number to hex. This is accomplished by:


Break the binary number into 4-bit sections from the LSB to the MSB.
Convert the 4-bit binary number to its Hex equivalent.


For example, the binary value 1010111110110010 will be written














1010 1111 1011 0010
A F B 2



 

 

Hex to Binary Conversion
It is also easy to convert from an integer hex number to binary. This is accomplished by:

Convert the Hex number to its 4-bit binary equivalent.
Combine the 4-bit sections by removing the spaces.

For example, the hex value 0AFB2 will be written:

 














A F B 2
1010 1111 1011 0010

 

This yields the binary number 1010111110110010 or 1010 1111 1011 0010 in our more readable format.

 

 

(c) Shilpa Sayura Foundation 2006-2017