We are going to share the techniques of conversion of decimal to binary number. You can easily learn how to convert decimal to binary and binary to decimal. You must be following steps one by one. First of all, you must be known about the decimal number and binary number.
What are the Base of Decimal and Binary number?
- The base of the Decimal number is 10. It means the decimal number is 0 to 9 (0,1,2,3,4,5,6,7,8,9)
- The base of the Binary number is 2. It means the binary number is 0 and 1.
This is the most important lesson to learn the conversion of decimal to binary.
There are two methods to convert decimal to binary.
- Shortcut method
- Long method
First of all we are going to describe the shortcut method to convert decimal to binary and again describe convert binary to decimal.
You can also watch this video regarding how to convert decimal to binary and binary to decimal.
Method 1: convert decimal to binary
You should follow those steps which is mention below with example.
Step 1: first of all draw a table with three 2 and 10 column
Step 2: in the first row fill the value of 2 to the power 0 to 9 in each column
28 | 27 | 26 | 25 | 24 | 23 | 22 | 21 | 20 |
256 | 128 | 64 | 32 | 16 | 8 | 4 | 2 | 1 |
Step 3: Compare the decimal number from (256, 128, 64,32, 16, 8, 4, 2, 1) less then and equal to
For example: Convert 28 in binary number
Step A. 28 Compare to number table, choose number less than equal to. 16 is the less then number from 28.
Step B. subtract 28 to 16 the reminder is 12 same process follow again and gain till the remind become 0.
Step c. fill the 0 in the blank column.
Step D. Right to left number is called Binary number
256 | 128 | 64 | 32 | 16 | 8 | 4 | 2 | 1 |
1 | 1 | 1 | 0 | 0 |
28-16= 12-8=4-4=0
Method 2: convert decimal to binary
- Divide the number by 2.
- Get the integer quotient for the next iteration.
- Get the remainder for the binary digit.
- Repeat the steps until the quotient is equal to 0.
Division by 2 | Decimal number | Reminder |
28/2 | 14 | 0 |
14/2 | 7 | 0 |
7/2 | 3 | 1 |
3/2 | 1 | 1 |
(28)10 = (11100)2