Binary Number 0 and 1

Used to describe a number system, or a number belonging to it, that has 2 rather than 10 as its base For instance, in a system called binary-coded decimal, each of the decimal digits 0 to 15 is coded in 4 bits.

Decimal       
Base 10 25 24 23 22 21 20
0   0000
1   0001
2   0010
3   0011
4   0100
5   0101
6   0110
7   0111
8   1000
9   1001
10   1010
11   1011
12   1100
13   1101
14   1110
15   1111

Binary to Base 10

Base 10 Base 2 (binary) How to calculate Base 10
0 0000 0x23+0x22+0x21+0x20 0+0+0+0
1 0001 0x23+0x22+0x21+1x20 0+0+0+1
2 0010 0x23+0x22+1x21+0x20 0+0+2+0
......      
15 1111 1x23+1x22+1x21+1x20 8+4+2+1


[Back]