Here we will see how you can **convert a number to binary format**, and we will also see how to **convert binary to decimal numbers**.

## How to convert a number into Binary?

In the further steps we will **convert 22 into binary format**, and you can **convert any number into binary by following the steps given below**.

**Divide the number by 2****Take the integer quotient for the next iteration****Take the remainder for the binary digit****Repeat the steps until the quotient is equal to 0****Arrange all the remainders from bottom to top**The

**binary format**of`22`

is`10110`

.

## Conversion from binary to decimal

`10110`

is the binary of `22`

. Now we will see how we can **get back the number from the binary format**.

Binary Number | 1 | 0 | 1 | 1 | 0 |

Power of 2 (from the right or bottom) | 2^{4} | 2^{3} | 2^{2} | 2^{1} | 2^{0} |

Power value (Ignore the zeros) | 16 | 4 | 2 |

Sum of **16+4+2** = **22**