Page 7 - Code Craft Computer-7
P. 7
A binary number is made up of only 0s and 1s.
Example of Binary Number: (110100)
2
There is no digit 2, 3, 4, 5, 6, 7, 8 or 9 in Binary number system.
Name Size (bits) Example
Bit 1 Single digit either 0 or 1
Nibble 4 Group of 4 digits
Byte 8 Group of 8 digits
Word 16 Group of 16 digits
Let us first learn how to form binary numbers.
As the binary number system consists of two digits 0 and 1 hence, its base is 2. Each digit or bit in
binary number system can be 0 or 1. A combination of binary digits may be used to represent
different quantities like 1001. The positional value of each digit in binary number is twice the
place value or face value of the digit of its right side. The weight of each position is a power of 2.
The place value of the digits according to position and weight is as follows:
Position 3 2 1 0 –1 –2
.
Weights 2 3 2 2 2 1 2 0 2 –1 2 –2
Extra Bytes
A single binary digit (like ‘0’ or ‘1’) is called a ‘bit’. For example (11010) is five bits long.
2
The word bit is made up from the words ‘Binary digit’.
Octal Number System
The octal number system consists of eight digits from 0 to 7. Hence, the base of octal number
system is 8. In this system, the position of each digit represents a power of 8. Any digit in this
system is always less than 8. Octal number system is used as a shorthand representation of
long binary numbers. The number (841) is invalid in this number system as 8 is not a valid
8
digit.
Hexadecimal Number System
The hexadecimal number system consists of 16 digits from 0 to 9 and A to F. The letters A to F
represent decimal numbers from 10 to 15. The base of this number system is 16. Each digit
position in hexadecimal number system represents a power of 16. For example, the number
(764) is a valid hexadecimal number. It is different from (764) which is seven hundred and
16 10
sixty four. This number system provides shortcut method to represent long binary numbers.
DECIMAL TO BINARY CONVERSION
To convert a decimal number into a binary number, follow these steps:
• Divide the decimal number by 2 (the base of the binary number system).
• Note down the quotient and the remainder.
7

