Good morning friends,
Today we are going to learn how to change decimal numbers to binary numbers using some basic operations.
Conversion steps:
- 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.
# example 1.
Q1. Convert 1510 to binary:.
Division by 2 | Quotient | Remainder | Bit # |
---|---|---|---|
15/2 | 7 | 1 | 0 |
7/2 | 3 | 1 | 1 |
3/2 | 1 | 1 | 2 |
1/2 | 0 | 1 | 3 |
1510 = 11112
#Example 2
Q2. Convert 17410 to binary:
Division by 2 | Quotient | Remainder | Bit # |
---|---|---|---|
174/2 | 87 | 0 | 0 |
87/2 | 43 | 1 | 1 |
43/2 | 21 | 1 | 2 |
21/2 | 10 | 1 | 3 |
10/2 | 5 | 0 | 4 |
5/2 | 2 | 1 | 5 |
2/2 | 1 | 0 | 6 |
1/2 | 0 | 1 | 7 |
So 17410 = 101011102
I hope you have understood that how to change decimal to binary.