Convert following binary numbers to decimal:
(a) 1010
(b) 1101101010
Answer:
- 1010
1010 2 = 1 x 2 3 + 0 x 2 2 + 1 x 2 1 + 0 x 2 0
= 8 + 0 + 2 + 0
= (10) 10
- 1101101010
1101101010 2 = 1 x 2 9 + 1 x 2 8 + 0 x 2 7 + 1 x 2 6 + 1 x 2 5 + 0 x 2 4 + 1 x 2 3 + 0 x 2 2 + 1 x 2 1 + 0 x 2 0
= 512 + 256 + 0 + 64 + 32 + 0 + 8 + 0 + 2 + 0
= (874) 10
Explanation:
- To obtain the decimal equivalent of a binary number, individual digits of binary number should be multiplied by powers of 2 starting with the rightmost digit multiplied by 2 0 , second last digit multiplied by 2 1 , third last digit multiplied by 2 2 and so on up to the leftmost digit.
- For digits after the decimal point, the leftmost digit should be multiplied by 2 -1 and the next digit by 2 -2 and so on up to the rightmost digit.