DoRevision

Conversion Clinic

Binary, denary and hex in every direction. Fill in the place-value columns, work down them to convert, and find out why the binary to hex direction needs no arithmetic at all.

⏱️ 22 min 🎯 14 activities
Best used for
Independent study Mock preparation Cover lesson

Get the method right under pressure

Free interactive practice on the steps that lose marks under exam pressure.

Start revising free

What you'll cover

From knowing to doing

You already know what the three bases are and why programmers use hex. This is the module where you get fast at moving between them. Here is the thing that makes it easy: there is no trick to memorise. Every conversion in this topic is the same one idea, which is that each column in a number is worth a fixed amount, and converting means working out or filling in those column values. Do that on paper and the arithmetic is simple addition or simple subtraction. Your specification says something else worth noticing too. It asks you to convert binary to hex a nibble at a time, and a nibble is four bits. That matters because it turns the hardest-looking conversion into the easiest one: going between binary and hex needs no arithmetic whatsoever, just a small lookup you can rebuild yourself in about ten seconds. Get the columns straight first, then meet the shortcut.

Words for the working

Five terms you need in order to describe what you are doing, not just to do it.

Write in the column values

An 8-bit number has eight columns, and each is worth twice the one to its right. Reading from the left they are _____, _____, _____, _____, 8, _____, 2 and 1. Writing this row out before you start is the working, and it is what stops you losing a mark to a miscounted column.

128 64 32 16 4 256 100 10 12 48

What does this byte come to

Convert the binary number 10110101 to denary. Write out your columns, add up the ones that have a 1 beneath them, and enter the total.

Two directions, two methods

Converting between binary and denary is easy in both directions, but you do something different each way. Knowing which is which is half the battle.

Order the subtraction method

Put the steps for converting a denary number into binary into the order you would carry them out.

  • Write out the eight column values, 128 down to 1
  • Find the largest column value that fits into your number
  • Write a 1 in that column and subtract its value from your number
  • Move right and repeat with whatever is left over
  • Write a 0 in any column whose value will not fit
  • Check that your bits add back up to the number you started with

Which byte is 173

Convert the denary number 173 into 8-bit binary. Which of these is correct?

  • 10101101
  • 10101100
  • 10101110
  • 10001101

Four bits at a time

This is the part that makes hex worth having, and it is what your specification means by converting a nibble at a time. Sixteen is two to the power of four, which means every hex digit corresponds to exactly four bits, always, with no exceptions. So converting between binary and hex involves no arithmetic at all. To go from binary to hex, split the byte down the middle into two nibbles, convert each nibble on its own, and write the two hex digits side by side. To go the other way, replace each hex digit with its four bits and push them together. Take 11010110. Split it into 1101 and 0110. The first nibble is 8 plus 4 plus 1, which is 13, and 13 is D. The second is 4 plus 2, which is 6. So the answer is D6, and at no point did you handle a number bigger than 15. Compare that with converting 11010110 straight to denary and then to hex, and you can see why programmers prefer it. You do not need to memorise the sixteen rows either: each one is just a four-bit number, so you can rebuild the whole table whenever you need it.

Each hex digit and its four bits

  • 1010
  • 1100
  • 1101
  • 1111
  • A
  • C
  • D
  • F

What is B7 worth

Convert the hexadecimal number B7 to denary. Remember that the left digit counts sixteens and the right digit counts ones, and that B is 11.

Split it into nibbles

Convert the binary number 11010110 into hexadecimal using the nibble method. Which answer is correct?

  • D6
  • 6D
  • C6
  • D5

The conversion that went wrong

Four statements from somebody's revision notes. Select the ONE that is incorrect.

  • 10100000 in binary is A0 in hex.
  • 00101101 in binary is 45 in denary.
  • 11001000 in binary is 100 in denary.
  • 1111 in binary is F in hex.

One number, three ways

Take the denary number 200 and write it in all three bases, showing the working at each stage. Start with the columns: 128, 64, 32, 16, 8, 4, 2, 1. Now subtract. 128 fits into 200 and leaves 72, so the 128 column gets a 1. 64 fits into 72 and leaves 8, so that column gets a 1 as well. 32 will not fit into 8, and neither will 16, so both take a 0. 8 fits exactly and leaves nothing, so the 8 column gets a 1 and the remaining columns take 0. That gives 11001000. Check it by adding back: 128 plus 64 plus 8 is 200, which is where you started. Now the hex, using the nibble method. Split 11001000 into 1100 and 1000. The first nibble is 8 plus 4, which is 12, and 12 is C. The second is 8. So the answer is C8. Notice how little arithmetic that last stage took, and notice that the check at the end cost you five seconds and would have caught any slip. That check is the habit worth taking into the exam.

Explain how you convert

A friend in your class can convert binary to denary but gets stuck going the other way and finds hex confusing. Explain the methods to them clearly.

  • List the eight column values of an 8-bit binary number
  • Explain how to convert binary to denary, and say what you do with columns that have a 0
  • Explain how to convert denary to binary, making clear that you subtract as you go
  • Explain what a nibble is and how many bits it contains
  • Explain why one hex digit corresponds to exactly four bits
  • Describe the nibble method for converting binary to hex, using an example of your own
  • Finish with the check you would do to make sure a conversion is right