Decimal/Binary Conversion Table

http://www.exploringbinary.com/decimal-binary-conversion-table/


Here is a table you can use to convert small integers — integers between 0 and 255 — directly between decimal and binary (as an alternative to using a decimal/binary converter):

Integers 0 to 255, in Decimal and Binary
Dec Binary Dec Binary Dec Binary Dec Binary
0 0 64 1000000 128 10000000 192 11000000
1 1 65 1000001 129 10000001 193 11000001
2 10 66 1000010 130 10000010 194 11000010
3 11 67 1000011 131 10000011 195 11000011
4 100 68 1000100 132 10000100 196 11000100
5 101 69 1000101 133 10000101 197 11000101
6 110 70 1000110 134 10000110 198 11000110
7 111 71 1000111 135 10000111 199 11000111
8 1000 72 1001000 136 10001000 200 11001000
9 1001 73 1001001 137 10001001 201 11001001
10 1010 74 1001010 138 10001010 202 11001010
11 1011 75 1001011 139 10001011 203 11001011
12 1100 76 1001100 140 10001100 204 11001100
13 1101 77 1001101 141 10001101 205 11001101
14 1110 78 1001110 142 10001110 206 11001110
15 1111 79 1001111 143 10001111 207 11001111
16 10000 80 1010000 144 10010000 208 11010000
17 10001 81 1010001 145 10010001 209 11010001
18 10010 82 1010010 146 10010010 210 11010010
19 10011 83 1010011 147 10010011 211 11010011
20 10100 84 1010100 148 10010100 212 11010100
21 10101 85 1010101 149 10010101 213 11010101
22 10110 86 1010110 150 10010110 214 11010110
23 10111 87 1010111 151 10010111 215 11010111
24 11000 88 1011000 152 10011000 216 11011000
25 11001 89 1011001 153 10011001 217 11011001
26 11010 90 1011010 154 10011010 218 11011010
27 11011 91 1011011 155 10011011 219 11011011
28 11100 92 1011100 156 10011100 220 11011100
29 11101 93 1011101 157 10011101 221 11011101
30 11110 94 1011110 158 10011110 222 11011110
31 11111 95 1011111 159 10011111 223 11011111
32 100000 96 1100000 160 10100000 224 11100000
33 100001 97 1100001 161 10100001 225 11100001
34 100010 98 1100010 162 10100010 226 11100010
35 100011 99 1100011 163 10100011 227 11100011
36 100100 100 1100100 164 10100100 228 11100100
37 100101 101 1100101 165 10100101 229 11100101
38 100110 102 1100110 166 10100110 230 11100110
39 100111 103 1100111 167 10100111 231 11100111
40 101000 104 1101000 168 10101000 232 11101000
41 101001 105 1101001 169 10101001 233 11101001
42 101010 106 1101010 170 10101010 234 11101010
43 101011 107 1101011 171 10101011 235 11101011
44 101100 108 1101100 172 10101100 236 11101100
45 101101 109 1101101 173 10101101 237 11101101
46 101110 110 1101110 174 10101110 238 11101110
47 101111 111 1101111 175 10101111 239 11101111
48 110000 112 1110000 176 10110000 240 11110000
49 110001 113 1110001 177 10110001 241 11110001
50 110010 114 1110010 178 10110010 242 11110010
51 110011 115 1110011 179 10110011 243 11110011
52 110100 116 1110100 180 10110100 244 11110100
53 110101 117 1110101 181 10110101 245 11110101
54 110110 118 1110110 182 10110110 246 11110110
55 110111 119 1110111 183 10110111 247 11110111
56 111000 120 1111000 184 10111000 248 11111000
57 111001 121 1111001 185 10111001 249 11111001
58 111010 122 1111010 186 10111010 250 11111010
59 111011 123 1111011 187 10111011 251 11111011
60 111100 124 1111100 188 10111100 252 11111100
61 111101 125 1111101 189 10111101 253 11111101
62 111110 126 1111110 190 10111110 254 11111110
63 111111 127 1111111 191 10111111 255 11111111

There are four columns of 64 entries each, totaling 256 entries.

If you are using these values for storage in a computer word — for example, a byte — be sure to pad with leading 0s, as necessary.

Dingbat

One Response to “Decimal/Binary Conversion Table”

  1. Patrick Potter Says:

    Awesome tool

Leave a Comment

(To reduce spam, cookies must be enabled)


css.php