Decimal-to-binary conversion works by systematically determining which powers of two fit into a given value. This foundational skill underpins how computers represent and process numeric data.
Decimal to Binary Conversion
Let's use our blocks to figure out how to convert from a decimal system to a binary system. So what we're going to do is we're going to start out with the decimal system here. And how much do we have? Well, we have one block of 100, and so that's 100, and we've got three one blocks, and so that's three. So 100 + 3 is 103.
Now let's convert that to binary. And the answer is still going to be 103, it's just we're going to allocate it a little differently. So what does that look like? Well, we can start with this 128 and say, is 128 larger than 103? And yes it is, so there's no 128 inside of this. Is 64 larger? No, it's not, so there's a 64, there's 64 blocks in 103. So what we can do is we can actually take that out of this and put it down here, and what that leaves us left over here is 39, 39 blocks left.
So do I have a 32 inside of the 39? Yes, 32 is not larger, it's smaller, so I can take out 32 blocks and I can put it right there. So now I have 011 so far. So then what I have left here is seven blocks. So if I count them up, I've got four, five, six, seven.
So is there a 16 in there? Nope, that's a larger number. Is there eight? Nope, that's a larger number. Is there a four? Yes, there is, I've got a four inside my seven here, so I can take four of them out, put them there. I've got three left. Is there two in there? Well, there certainly is, so I've got that now. And there's one left, that can go right there.
So now what I've just done is I've converted it now from my 103 in decimal to a 01100111.
TechKnowSurge builds IT and cybersecurity professionals through hands-on, concept-first training built around real understanding — not memorization. Free interactive tools, structured programs, and 25+ years of real-world experience, all in one place.
Explore free tools and programs →