Binary conversion formula
Binary, octal and hexadecimal can all be converted into decimal. The method is to multiply each number by the N- 1 power of their respective cardinality, and then add them to get the corresponding decimal number.
Binary to decimal
For example, when the binary number 1 10B is converted into decimal, it is1* 2+1* 20 = 4+2+0 = 6d.
Decimal to binary
Conversely, decimal can also be converted into binary, octal and hexadecimal. The method is to divide by the number to be converted and write down the remainder of each time until the remainder is 0.
Octal to decimal
For example, 100D is converted into octal, which is 144Q, where100/8 =12/8 =1... 41/8 = 0 ... 66.
Hexadecimal to decimal
Similarly, hexadecimal can also be converted into decimal. This method is similar to binary and octal, but the radix is changed to 16.