01How Computers Work

Fully solved problem book

Signed eight-bit values

Set 7 of 8 · 32 worked questions. Predict your result before expanding the solution.

These worked traces are meant to build fluency through controlled variation. If several answers feel identical, try the next difficult value and look for the point where a carry, sign, branch, or selected memory address changes the outcome.

Foundations · Problem 0193

Interpret 11000000 as an 8-bit two’s complement value.

Try it on paper first. The worked answer is hidden below.

Reveal detailed solution →
  1. Treat 11000000 as exactly eight bits.
  2. For signed 8-bit values the leftmost column has weight −128, not +128.
  3. The remaining seven columns have weights 64, 32, 16, 8, 4, 2 and 1.
  4. The leading sign bit is 1, so its signed contribution is -128.
  5. The lower seven bits contribute 64.
  6. Add those contributions: -128 + 64 = -64.
  7. As an unsigned pattern, the same eight bits represent 192.
  8. The signed range for eight bits is −128 through +127.
  9. Bitwise inversion alone yields 00111111; inversion plus one wraps modulo 256.
  10. The eight-bit negated pattern is 01000000.
  11. Answer: signed(11000000) = -64.

Final answer: -64

Foundations · Problem 0194

Interpret 11000001 as an 8-bit two’s complement value.

Try it on paper first. The worked answer is hidden below.

Reveal detailed solution →
  1. Treat 11000001 as exactly eight bits.
  2. For signed 8-bit values the leftmost column has weight −128, not +128.
  3. The remaining seven columns have weights 64, 32, 16, 8, 4, 2 and 1.
  4. The leading sign bit is 1, so its signed contribution is -128.
  5. The lower seven bits contribute 65.
  6. Add those contributions: -128 + 65 = -63.
  7. As an unsigned pattern, the same eight bits represent 193.
  8. The signed range for eight bits is −128 through +127.
  9. Bitwise inversion alone yields 00111110; inversion plus one wraps modulo 256.
  10. The eight-bit negated pattern is 00111111.
  11. Answer: signed(11000001) = -63.

Final answer: -63

Foundations · Problem 0195

Interpret 11000010 as an 8-bit two’s complement value.

Try it on paper first. The worked answer is hidden below.

Reveal detailed solution →
  1. Treat 11000010 as exactly eight bits.
  2. For signed 8-bit values the leftmost column has weight −128, not +128.
  3. The remaining seven columns have weights 64, 32, 16, 8, 4, 2 and 1.
  4. The leading sign bit is 1, so its signed contribution is -128.
  5. The lower seven bits contribute 66.
  6. Add those contributions: -128 + 66 = -62.
  7. As an unsigned pattern, the same eight bits represent 194.
  8. The signed range for eight bits is −128 through +127.
  9. Bitwise inversion alone yields 00111101; inversion plus one wraps modulo 256.
  10. The eight-bit negated pattern is 00111110.
  11. Answer: signed(11000010) = -62.

Final answer: -62

Foundations · Problem 0196

Interpret 11000011 as an 8-bit two’s complement value.

Try it on paper first. The worked answer is hidden below.

Reveal detailed solution →
  1. Treat 11000011 as exactly eight bits.
  2. For signed 8-bit values the leftmost column has weight −128, not +128.
  3. The remaining seven columns have weights 64, 32, 16, 8, 4, 2 and 1.
  4. The leading sign bit is 1, so its signed contribution is -128.
  5. The lower seven bits contribute 67.
  6. Add those contributions: -128 + 67 = -61.
  7. As an unsigned pattern, the same eight bits represent 195.
  8. The signed range for eight bits is −128 through +127.
  9. Bitwise inversion alone yields 00111100; inversion plus one wraps modulo 256.
  10. The eight-bit negated pattern is 00111101.
  11. Answer: signed(11000011) = -61.

Final answer: -61

Foundations · Problem 0197

Interpret 11000100 as an 8-bit two’s complement value.

Try it on paper first. The worked answer is hidden below.

Reveal detailed solution →
  1. Treat 11000100 as exactly eight bits.
  2. For signed 8-bit values the leftmost column has weight −128, not +128.
  3. The remaining seven columns have weights 64, 32, 16, 8, 4, 2 and 1.
  4. The leading sign bit is 1, so its signed contribution is -128.
  5. The lower seven bits contribute 68.
  6. Add those contributions: -128 + 68 = -60.
  7. As an unsigned pattern, the same eight bits represent 196.
  8. The signed range for eight bits is −128 through +127.
  9. Bitwise inversion alone yields 00111011; inversion plus one wraps modulo 256.
  10. The eight-bit negated pattern is 00111100.
  11. Answer: signed(11000100) = -60.

Final answer: -60

Foundations · Problem 0198

Interpret 11000101 as an 8-bit two’s complement value.

Try it on paper first. The worked answer is hidden below.

Reveal detailed solution →
  1. Treat 11000101 as exactly eight bits.
  2. For signed 8-bit values the leftmost column has weight −128, not +128.
  3. The remaining seven columns have weights 64, 32, 16, 8, 4, 2 and 1.
  4. The leading sign bit is 1, so its signed contribution is -128.
  5. The lower seven bits contribute 69.
  6. Add those contributions: -128 + 69 = -59.
  7. As an unsigned pattern, the same eight bits represent 197.
  8. The signed range for eight bits is −128 through +127.
  9. Bitwise inversion alone yields 00111010; inversion plus one wraps modulo 256.
  10. The eight-bit negated pattern is 00111011.
  11. Answer: signed(11000101) = -59.

Final answer: -59

Foundations · Problem 0199

Interpret 11000110 as an 8-bit two’s complement value.

Try it on paper first. The worked answer is hidden below.

Reveal detailed solution →
  1. Treat 11000110 as exactly eight bits.
  2. For signed 8-bit values the leftmost column has weight −128, not +128.
  3. The remaining seven columns have weights 64, 32, 16, 8, 4, 2 and 1.
  4. The leading sign bit is 1, so its signed contribution is -128.
  5. The lower seven bits contribute 70.
  6. Add those contributions: -128 + 70 = -58.
  7. As an unsigned pattern, the same eight bits represent 198.
  8. The signed range for eight bits is −128 through +127.
  9. Bitwise inversion alone yields 00111001; inversion plus one wraps modulo 256.
  10. The eight-bit negated pattern is 00111010.
  11. Answer: signed(11000110) = -58.

Final answer: -58

Foundations · Problem 0200

Interpret 11000111 as an 8-bit two’s complement value.

Try it on paper first. The worked answer is hidden below.

Reveal detailed solution →
  1. Treat 11000111 as exactly eight bits.
  2. For signed 8-bit values the leftmost column has weight −128, not +128.
  3. The remaining seven columns have weights 64, 32, 16, 8, 4, 2 and 1.
  4. The leading sign bit is 1, so its signed contribution is -128.
  5. The lower seven bits contribute 71.
  6. Add those contributions: -128 + 71 = -57.
  7. As an unsigned pattern, the same eight bits represent 199.
  8. The signed range for eight bits is −128 through +127.
  9. Bitwise inversion alone yields 00111000; inversion plus one wraps modulo 256.
  10. The eight-bit negated pattern is 00111001.
  11. Answer: signed(11000111) = -57.

Final answer: -57

Foundations · Problem 0201

Interpret 11001000 as an 8-bit two’s complement value.

Try it on paper first. The worked answer is hidden below.

Reveal detailed solution →
  1. Treat 11001000 as exactly eight bits.
  2. For signed 8-bit values the leftmost column has weight −128, not +128.
  3. The remaining seven columns have weights 64, 32, 16, 8, 4, 2 and 1.
  4. The leading sign bit is 1, so its signed contribution is -128.
  5. The lower seven bits contribute 72.
  6. Add those contributions: -128 + 72 = -56.
  7. As an unsigned pattern, the same eight bits represent 200.
  8. The signed range for eight bits is −128 through +127.
  9. Bitwise inversion alone yields 00110111; inversion plus one wraps modulo 256.
  10. The eight-bit negated pattern is 00111000.
  11. Answer: signed(11001000) = -56.

Final answer: -56

Foundations · Problem 0202

Interpret 11001001 as an 8-bit two’s complement value.

Try it on paper first. The worked answer is hidden below.

Reveal detailed solution →
  1. Treat 11001001 as exactly eight bits.
  2. For signed 8-bit values the leftmost column has weight −128, not +128.
  3. The remaining seven columns have weights 64, 32, 16, 8, 4, 2 and 1.
  4. The leading sign bit is 1, so its signed contribution is -128.
  5. The lower seven bits contribute 73.
  6. Add those contributions: -128 + 73 = -55.
  7. As an unsigned pattern, the same eight bits represent 201.
  8. The signed range for eight bits is −128 through +127.
  9. Bitwise inversion alone yields 00110110; inversion plus one wraps modulo 256.
  10. The eight-bit negated pattern is 00110111.
  11. Answer: signed(11001001) = -55.

Final answer: -55

Foundations · Problem 0203

Interpret 11001010 as an 8-bit two’s complement value.

Try it on paper first. The worked answer is hidden below.

Reveal detailed solution →
  1. Treat 11001010 as exactly eight bits.
  2. For signed 8-bit values the leftmost column has weight −128, not +128.
  3. The remaining seven columns have weights 64, 32, 16, 8, 4, 2 and 1.
  4. The leading sign bit is 1, so its signed contribution is -128.
  5. The lower seven bits contribute 74.
  6. Add those contributions: -128 + 74 = -54.
  7. As an unsigned pattern, the same eight bits represent 202.
  8. The signed range for eight bits is −128 through +127.
  9. Bitwise inversion alone yields 00110101; inversion plus one wraps modulo 256.
  10. The eight-bit negated pattern is 00110110.
  11. Answer: signed(11001010) = -54.

Final answer: -54

Foundations · Problem 0204

Interpret 11001011 as an 8-bit two’s complement value.

Try it on paper first. The worked answer is hidden below.

Reveal detailed solution →
  1. Treat 11001011 as exactly eight bits.
  2. For signed 8-bit values the leftmost column has weight −128, not +128.
  3. The remaining seven columns have weights 64, 32, 16, 8, 4, 2 and 1.
  4. The leading sign bit is 1, so its signed contribution is -128.
  5. The lower seven bits contribute 75.
  6. Add those contributions: -128 + 75 = -53.
  7. As an unsigned pattern, the same eight bits represent 203.
  8. The signed range for eight bits is −128 through +127.
  9. Bitwise inversion alone yields 00110100; inversion plus one wraps modulo 256.
  10. The eight-bit negated pattern is 00110101.
  11. Answer: signed(11001011) = -53.

Final answer: -53

Foundations · Problem 0205

Interpret 11001100 as an 8-bit two’s complement value.

Try it on paper first. The worked answer is hidden below.

Reveal detailed solution →
  1. Treat 11001100 as exactly eight bits.
  2. For signed 8-bit values the leftmost column has weight −128, not +128.
  3. The remaining seven columns have weights 64, 32, 16, 8, 4, 2 and 1.
  4. The leading sign bit is 1, so its signed contribution is -128.
  5. The lower seven bits contribute 76.
  6. Add those contributions: -128 + 76 = -52.
  7. As an unsigned pattern, the same eight bits represent 204.
  8. The signed range for eight bits is −128 through +127.
  9. Bitwise inversion alone yields 00110011; inversion plus one wraps modulo 256.
  10. The eight-bit negated pattern is 00110100.
  11. Answer: signed(11001100) = -52.

Final answer: -52

Foundations · Problem 0206

Interpret 11001101 as an 8-bit two’s complement value.

Try it on paper first. The worked answer is hidden below.

Reveal detailed solution →
  1. Treat 11001101 as exactly eight bits.
  2. For signed 8-bit values the leftmost column has weight −128, not +128.
  3. The remaining seven columns have weights 64, 32, 16, 8, 4, 2 and 1.
  4. The leading sign bit is 1, so its signed contribution is -128.
  5. The lower seven bits contribute 77.
  6. Add those contributions: -128 + 77 = -51.
  7. As an unsigned pattern, the same eight bits represent 205.
  8. The signed range for eight bits is −128 through +127.
  9. Bitwise inversion alone yields 00110010; inversion plus one wraps modulo 256.
  10. The eight-bit negated pattern is 00110011.
  11. Answer: signed(11001101) = -51.

Final answer: -51

Foundations · Problem 0207

Interpret 11001110 as an 8-bit two’s complement value.

Try it on paper first. The worked answer is hidden below.

Reveal detailed solution →
  1. Treat 11001110 as exactly eight bits.
  2. For signed 8-bit values the leftmost column has weight −128, not +128.
  3. The remaining seven columns have weights 64, 32, 16, 8, 4, 2 and 1.
  4. The leading sign bit is 1, so its signed contribution is -128.
  5. The lower seven bits contribute 78.
  6. Add those contributions: -128 + 78 = -50.
  7. As an unsigned pattern, the same eight bits represent 206.
  8. The signed range for eight bits is −128 through +127.
  9. Bitwise inversion alone yields 00110001; inversion plus one wraps modulo 256.
  10. The eight-bit negated pattern is 00110010.
  11. Answer: signed(11001110) = -50.

Final answer: -50

Foundations · Problem 0208

Interpret 11001111 as an 8-bit two’s complement value.

Try it on paper first. The worked answer is hidden below.

Reveal detailed solution →
  1. Treat 11001111 as exactly eight bits.
  2. For signed 8-bit values the leftmost column has weight −128, not +128.
  3. The remaining seven columns have weights 64, 32, 16, 8, 4, 2 and 1.
  4. The leading sign bit is 1, so its signed contribution is -128.
  5. The lower seven bits contribute 79.
  6. Add those contributions: -128 + 79 = -49.
  7. As an unsigned pattern, the same eight bits represent 207.
  8. The signed range for eight bits is −128 through +127.
  9. Bitwise inversion alone yields 00110000; inversion plus one wraps modulo 256.
  10. The eight-bit negated pattern is 00110001.
  11. Answer: signed(11001111) = -49.

Final answer: -49

Foundations · Problem 0209

Interpret 11010000 as an 8-bit two’s complement value.

Try it on paper first. The worked answer is hidden below.

Reveal detailed solution →
  1. Treat 11010000 as exactly eight bits.
  2. For signed 8-bit values the leftmost column has weight −128, not +128.
  3. The remaining seven columns have weights 64, 32, 16, 8, 4, 2 and 1.
  4. The leading sign bit is 1, so its signed contribution is -128.
  5. The lower seven bits contribute 80.
  6. Add those contributions: -128 + 80 = -48.
  7. As an unsigned pattern, the same eight bits represent 208.
  8. The signed range for eight bits is −128 through +127.
  9. Bitwise inversion alone yields 00101111; inversion plus one wraps modulo 256.
  10. The eight-bit negated pattern is 00110000.
  11. Answer: signed(11010000) = -48.

Final answer: -48

Foundations · Problem 0210

Interpret 11010001 as an 8-bit two’s complement value.

Try it on paper first. The worked answer is hidden below.

Reveal detailed solution →
  1. Treat 11010001 as exactly eight bits.
  2. For signed 8-bit values the leftmost column has weight −128, not +128.
  3. The remaining seven columns have weights 64, 32, 16, 8, 4, 2 and 1.
  4. The leading sign bit is 1, so its signed contribution is -128.
  5. The lower seven bits contribute 81.
  6. Add those contributions: -128 + 81 = -47.
  7. As an unsigned pattern, the same eight bits represent 209.
  8. The signed range for eight bits is −128 through +127.
  9. Bitwise inversion alone yields 00101110; inversion plus one wraps modulo 256.
  10. The eight-bit negated pattern is 00101111.
  11. Answer: signed(11010001) = -47.

Final answer: -47

Foundations · Problem 0211

Interpret 11010010 as an 8-bit two’s complement value.

Try it on paper first. The worked answer is hidden below.

Reveal detailed solution →
  1. Treat 11010010 as exactly eight bits.
  2. For signed 8-bit values the leftmost column has weight −128, not +128.
  3. The remaining seven columns have weights 64, 32, 16, 8, 4, 2 and 1.
  4. The leading sign bit is 1, so its signed contribution is -128.
  5. The lower seven bits contribute 82.
  6. Add those contributions: -128 + 82 = -46.
  7. As an unsigned pattern, the same eight bits represent 210.
  8. The signed range for eight bits is −128 through +127.
  9. Bitwise inversion alone yields 00101101; inversion plus one wraps modulo 256.
  10. The eight-bit negated pattern is 00101110.
  11. Answer: signed(11010010) = -46.

Final answer: -46

Foundations · Problem 0212

Interpret 11010011 as an 8-bit two’s complement value.

Try it on paper first. The worked answer is hidden below.

Reveal detailed solution →
  1. Treat 11010011 as exactly eight bits.
  2. For signed 8-bit values the leftmost column has weight −128, not +128.
  3. The remaining seven columns have weights 64, 32, 16, 8, 4, 2 and 1.
  4. The leading sign bit is 1, so its signed contribution is -128.
  5. The lower seven bits contribute 83.
  6. Add those contributions: -128 + 83 = -45.
  7. As an unsigned pattern, the same eight bits represent 211.
  8. The signed range for eight bits is −128 through +127.
  9. Bitwise inversion alone yields 00101100; inversion plus one wraps modulo 256.
  10. The eight-bit negated pattern is 00101101.
  11. Answer: signed(11010011) = -45.

Final answer: -45

Foundations · Problem 0213

Interpret 11010100 as an 8-bit two’s complement value.

Try it on paper first. The worked answer is hidden below.

Reveal detailed solution →
  1. Treat 11010100 as exactly eight bits.
  2. For signed 8-bit values the leftmost column has weight −128, not +128.
  3. The remaining seven columns have weights 64, 32, 16, 8, 4, 2 and 1.
  4. The leading sign bit is 1, so its signed contribution is -128.
  5. The lower seven bits contribute 84.
  6. Add those contributions: -128 + 84 = -44.
  7. As an unsigned pattern, the same eight bits represent 212.
  8. The signed range for eight bits is −128 through +127.
  9. Bitwise inversion alone yields 00101011; inversion plus one wraps modulo 256.
  10. The eight-bit negated pattern is 00101100.
  11. Answer: signed(11010100) = -44.

Final answer: -44

Foundations · Problem 0214

Interpret 11010101 as an 8-bit two’s complement value.

Try it on paper first. The worked answer is hidden below.

Reveal detailed solution →
  1. Treat 11010101 as exactly eight bits.
  2. For signed 8-bit values the leftmost column has weight −128, not +128.
  3. The remaining seven columns have weights 64, 32, 16, 8, 4, 2 and 1.
  4. The leading sign bit is 1, so its signed contribution is -128.
  5. The lower seven bits contribute 85.
  6. Add those contributions: -128 + 85 = -43.
  7. As an unsigned pattern, the same eight bits represent 213.
  8. The signed range for eight bits is −128 through +127.
  9. Bitwise inversion alone yields 00101010; inversion plus one wraps modulo 256.
  10. The eight-bit negated pattern is 00101011.
  11. Answer: signed(11010101) = -43.

Final answer: -43

Foundations · Problem 0215

Interpret 11010110 as an 8-bit two’s complement value.

Try it on paper first. The worked answer is hidden below.

Reveal detailed solution →
  1. Treat 11010110 as exactly eight bits.
  2. For signed 8-bit values the leftmost column has weight −128, not +128.
  3. The remaining seven columns have weights 64, 32, 16, 8, 4, 2 and 1.
  4. The leading sign bit is 1, so its signed contribution is -128.
  5. The lower seven bits contribute 86.
  6. Add those contributions: -128 + 86 = -42.
  7. As an unsigned pattern, the same eight bits represent 214.
  8. The signed range for eight bits is −128 through +127.
  9. Bitwise inversion alone yields 00101001; inversion plus one wraps modulo 256.
  10. The eight-bit negated pattern is 00101010.
  11. Answer: signed(11010110) = -42.

Final answer: -42

Foundations · Problem 0216

Interpret 11010111 as an 8-bit two’s complement value.

Try it on paper first. The worked answer is hidden below.

Reveal detailed solution →
  1. Treat 11010111 as exactly eight bits.
  2. For signed 8-bit values the leftmost column has weight −128, not +128.
  3. The remaining seven columns have weights 64, 32, 16, 8, 4, 2 and 1.
  4. The leading sign bit is 1, so its signed contribution is -128.
  5. The lower seven bits contribute 87.
  6. Add those contributions: -128 + 87 = -41.
  7. As an unsigned pattern, the same eight bits represent 215.
  8. The signed range for eight bits is −128 through +127.
  9. Bitwise inversion alone yields 00101000; inversion plus one wraps modulo 256.
  10. The eight-bit negated pattern is 00101001.
  11. Answer: signed(11010111) = -41.

Final answer: -41

Foundations · Problem 0217

Interpret 11011000 as an 8-bit two’s complement value.

Try it on paper first. The worked answer is hidden below.

Reveal detailed solution →
  1. Treat 11011000 as exactly eight bits.
  2. For signed 8-bit values the leftmost column has weight −128, not +128.
  3. The remaining seven columns have weights 64, 32, 16, 8, 4, 2 and 1.
  4. The leading sign bit is 1, so its signed contribution is -128.
  5. The lower seven bits contribute 88.
  6. Add those contributions: -128 + 88 = -40.
  7. As an unsigned pattern, the same eight bits represent 216.
  8. The signed range for eight bits is −128 through +127.
  9. Bitwise inversion alone yields 00100111; inversion plus one wraps modulo 256.
  10. The eight-bit negated pattern is 00101000.
  11. Answer: signed(11011000) = -40.

Final answer: -40

Foundations · Problem 0218

Interpret 11011001 as an 8-bit two’s complement value.

Try it on paper first. The worked answer is hidden below.

Reveal detailed solution →
  1. Treat 11011001 as exactly eight bits.
  2. For signed 8-bit values the leftmost column has weight −128, not +128.
  3. The remaining seven columns have weights 64, 32, 16, 8, 4, 2 and 1.
  4. The leading sign bit is 1, so its signed contribution is -128.
  5. The lower seven bits contribute 89.
  6. Add those contributions: -128 + 89 = -39.
  7. As an unsigned pattern, the same eight bits represent 217.
  8. The signed range for eight bits is −128 through +127.
  9. Bitwise inversion alone yields 00100110; inversion plus one wraps modulo 256.
  10. The eight-bit negated pattern is 00100111.
  11. Answer: signed(11011001) = -39.

Final answer: -39

Foundations · Problem 0219

Interpret 11011010 as an 8-bit two’s complement value.

Try it on paper first. The worked answer is hidden below.

Reveal detailed solution →
  1. Treat 11011010 as exactly eight bits.
  2. For signed 8-bit values the leftmost column has weight −128, not +128.
  3. The remaining seven columns have weights 64, 32, 16, 8, 4, 2 and 1.
  4. The leading sign bit is 1, so its signed contribution is -128.
  5. The lower seven bits contribute 90.
  6. Add those contributions: -128 + 90 = -38.
  7. As an unsigned pattern, the same eight bits represent 218.
  8. The signed range for eight bits is −128 through +127.
  9. Bitwise inversion alone yields 00100101; inversion plus one wraps modulo 256.
  10. The eight-bit negated pattern is 00100110.
  11. Answer: signed(11011010) = -38.

Final answer: -38

Foundations · Problem 0220

Interpret 11011011 as an 8-bit two’s complement value.

Try it on paper first. The worked answer is hidden below.

Reveal detailed solution →
  1. Treat 11011011 as exactly eight bits.
  2. For signed 8-bit values the leftmost column has weight −128, not +128.
  3. The remaining seven columns have weights 64, 32, 16, 8, 4, 2 and 1.
  4. The leading sign bit is 1, so its signed contribution is -128.
  5. The lower seven bits contribute 91.
  6. Add those contributions: -128 + 91 = -37.
  7. As an unsigned pattern, the same eight bits represent 219.
  8. The signed range for eight bits is −128 through +127.
  9. Bitwise inversion alone yields 00100100; inversion plus one wraps modulo 256.
  10. The eight-bit negated pattern is 00100101.
  11. Answer: signed(11011011) = -37.

Final answer: -37

Foundations · Problem 0221

Interpret 11011100 as an 8-bit two’s complement value.

Try it on paper first. The worked answer is hidden below.

Reveal detailed solution →
  1. Treat 11011100 as exactly eight bits.
  2. For signed 8-bit values the leftmost column has weight −128, not +128.
  3. The remaining seven columns have weights 64, 32, 16, 8, 4, 2 and 1.
  4. The leading sign bit is 1, so its signed contribution is -128.
  5. The lower seven bits contribute 92.
  6. Add those contributions: -128 + 92 = -36.
  7. As an unsigned pattern, the same eight bits represent 220.
  8. The signed range for eight bits is −128 through +127.
  9. Bitwise inversion alone yields 00100011; inversion plus one wraps modulo 256.
  10. The eight-bit negated pattern is 00100100.
  11. Answer: signed(11011100) = -36.

Final answer: -36

Foundations · Problem 0222

Interpret 11011101 as an 8-bit two’s complement value.

Try it on paper first. The worked answer is hidden below.

Reveal detailed solution →
  1. Treat 11011101 as exactly eight bits.
  2. For signed 8-bit values the leftmost column has weight −128, not +128.
  3. The remaining seven columns have weights 64, 32, 16, 8, 4, 2 and 1.
  4. The leading sign bit is 1, so its signed contribution is -128.
  5. The lower seven bits contribute 93.
  6. Add those contributions: -128 + 93 = -35.
  7. As an unsigned pattern, the same eight bits represent 221.
  8. The signed range for eight bits is −128 through +127.
  9. Bitwise inversion alone yields 00100010; inversion plus one wraps modulo 256.
  10. The eight-bit negated pattern is 00100011.
  11. Answer: signed(11011101) = -35.

Final answer: -35

Foundations · Problem 0223

Interpret 11011110 as an 8-bit two’s complement value.

Try it on paper first. The worked answer is hidden below.

Reveal detailed solution →
  1. Treat 11011110 as exactly eight bits.
  2. For signed 8-bit values the leftmost column has weight −128, not +128.
  3. The remaining seven columns have weights 64, 32, 16, 8, 4, 2 and 1.
  4. The leading sign bit is 1, so its signed contribution is -128.
  5. The lower seven bits contribute 94.
  6. Add those contributions: -128 + 94 = -34.
  7. As an unsigned pattern, the same eight bits represent 222.
  8. The signed range for eight bits is −128 through +127.
  9. Bitwise inversion alone yields 00100001; inversion plus one wraps modulo 256.
  10. The eight-bit negated pattern is 00100010.
  11. Answer: signed(11011110) = -34.

Final answer: -34

Foundations · Problem 0224

Interpret 11011111 as an 8-bit two’s complement value.

Try it on paper first. The worked answer is hidden below.

Reveal detailed solution →
  1. Treat 11011111 as exactly eight bits.
  2. For signed 8-bit values the leftmost column has weight −128, not +128.
  3. The remaining seven columns have weights 64, 32, 16, 8, 4, 2 and 1.
  4. The leading sign bit is 1, so its signed contribution is -128.
  5. The lower seven bits contribute 95.
  6. Add those contributions: -128 + 95 = -33.
  7. As an unsigned pattern, the same eight bits represent 223.
  8. The signed range for eight bits is −128 through +127.
  9. Bitwise inversion alone yields 00100000; inversion plus one wraps modulo 256.
  10. The eight-bit negated pattern is 00100001.
  11. Answer: signed(11011111) = -33.

Final answer: -33