﻿ Bits 'N' Bytes -- Bits and Nibbles

You are at the section Bits 'N' Bytes

## Bits and Nibbles

Bits are on the Base 2 system, that is, a number set of just two digits: 0 and 1.

A bit is the most basic part of memory.

Four bits makes a nibble. By combining the digits of 0 and 1, you can create 16 unique values ranging from 0000 to 1111.

Each bit in a nibble represents a power of 2. The left-most digit is 2³ (8), the second-to-left is 2² (4), then the second-to-last is 2¹ (2), then the right-most digit being 2⁰ (1).

Each bit in a nibble represents a power of 2 as you can see in this chart. Notw that the "Bit Column" represents a digit position couting upwards from the right end of the byte towards the left.

Bit ColumnPower of 2Hex ValueDecimal Value
02⁰11
122
244
388

To represent, for example, a number 9, you would need a nibble of 1001, with the left-most digit being 8 and the right-most digit being 1, so 8 + 1 = 9.

To represent, for example, a number 12, you would need a nibble of 1100, with the left-most digit being 8 and the next-to-left-most digit being 4, so 8 + 4 = 12. 12 in decimal is also the hexadecimal digit of C, in fact, the complete range of hexadecimal digits are represented by a nibble.

BitsDecimal ValueHexadecimal Value
000000
000111
001022
001133
010044
010155
011066
011177
100088
100199
101010A
101111B
110012C
110113D
111014E
111115F

﻿

﻿

© 1995-2019. davesfunstuff.com All Rights Reserved. Reproduction of any part of this website without expressed written consent is prohibited.   