Contact Us

Decimal to binary conversion

Reading Time: 2 min

Tags:  Computer Science

In this article, I will describe one of the easiest methods for converting decimal numbers to binary. It is especially useful when there are multiple numbers to convert.

Make a list of all the powers of 2, starting with 2 up to the number you want to convert. Please note that this is an inclusive range. So if the number is a power of two, it must be included in the list. Make sure to write the list in descending order. For example, if the number is 73; 64 is the largest power of two which is not larger than 73. So the list must contain the numbers 64, 32, 16, 8, 4, 2, and 1. You could think of the elements in this list as the column headings of a table; please refer to the image below. Let us look at the steps needed to convert 73 to binary.

This method has the disadvantage that we need to prepare a list of powers of two first. But we can treat elements of this list like the column headings of a table. This allows us to convert multiple numbers using a single list.