liveBook · Manning

Binary-to-decimal conversion

As explained in Acing the CCNA Exam: Volume 1 Fundamentals and Protocols

Binary-to-decimal conversion is the process of calculating a decimal value by summing the positional values of the set bits in a binary number.

Binary-to-decimal conversion calculates a decimal value by adding the positional values of every bit set to 1. For IPv4, work with four separate 8-bit groups rather than all 32 bits at once. section 7.2.2

Figure 7.4 An 8-bit (1-byte) number with the value of each bit written above. The decimal equivalent of 0b10101101 is 0d173. This can be calculated by adding the value of each bit that is set to 1.

Use the bit-value figure to identify each position’s decimal value before adding the values of the set bits. section 7.2.2

Convert an 8-bit binary number as follows:

  • Write the positional values from left to right: 128, 64, 32, 16, 8, 4, 2, and 1. section 7.2.2
  • Ignore positions containing 0, then add the values of positions containing 1. section 7.2.2
  • Check that the result falls between 0 and 255; eight bits provide 256 possible values. section 7.2.2

Worked example

For 00101111, add 32 + 8 + 4 + 2 + 1. The decimal result is 47. Practice with random 8-bit values until the calculation becomes mental. section 7.2.2

How Acing the CCNA Exam: Volume 1 Fundamentals and Protocols covers it

How deep it goes
Explains positional addition, validates the 0–255 range, and stops short of requiring full 32-bit conversion.
Examples
Uses 00101111 = 47 and encourages practice with random 8-bit values such as 11011010 and 01011100.
What it assumes
Recognizes binary digits and bit positions; teaches the relevant 8-bit values from the fundamentals.
What you can do after
Apply positional addition to convert any 8-bit binary number into decimal, including IPv4 address groups.
How it connects
Connects binary numbers, decimal numbers, bits, and IPv4 addressing through 8-bit positional values.

Related concepts

This explainer was generated by Manning's knowledge graph from the text of Acing the CCNA Exam: Volume 1 Fundamentals and Protocols. The section links point to the parts of the book it draws on.