Fully solved problem book
RAM addressing
Set 3 of 6 · 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.
State and memory · Problem 0065
RAM[3] initially stores 64. Write 83 there, then read the same location. What returns?
Try it on paper first. The worked answer is hidden below.
Reveal detailed solution →
- The machine models 16 byte-wide addresses: 0–15.
- Each location stores an eight-bit data word.
- At the start, RAM[3] contains 01000000 (64 unsigned).
- The CPU puts the four-bit address 0011 on the address lines.
- The decoder selects row 3, not row 8.
- Write-enable becomes active and the incoming data lines carry 01010011.
- The selected stored byte is replaced with 01010011.
- The write does not inherently change RAM[8].
- A later read of row 3 selects the new contents.
- The output data is 01010011, which equals 83 decimal.
- The address determines WHERE the information is stored; the data determines WHAT is stored.
Final answer: 83
State and memory · Problem 0066
RAM[10] initially stores 77. Write 120 there, then read the same location. What returns?
Try it on paper first. The worked answer is hidden below.
Reveal detailed solution →
- The machine models 16 byte-wide addresses: 0–15.
- Each location stores an eight-bit data word.
- At the start, RAM[10] contains 01001101 (77 unsigned).
- The CPU puts the four-bit address 1010 on the address lines.
- The decoder selects row 10, not row 15.
- Write-enable becomes active and the incoming data lines carry 01111000.
- The selected stored byte is replaced with 01111000.
- The write does not inherently change RAM[15].
- A later read of row 10 selects the new contents.
- The output data is 01111000, which equals 120 decimal.
- The address determines WHERE the information is stored; the data determines WHAT is stored.
Final answer: 120
State and memory · Problem 0067
RAM[1] initially stores 90. Write 157 there, then read the same location. What returns?
Try it on paper first. The worked answer is hidden below.
Reveal detailed solution →
- The machine models 16 byte-wide addresses: 0–15.
- Each location stores an eight-bit data word.
- At the start, RAM[1] contains 01011010 (90 unsigned).
- The CPU puts the four-bit address 0001 on the address lines.
- The decoder selects row 1, not row 6.
- Write-enable becomes active and the incoming data lines carry 10011101.
- The selected stored byte is replaced with 10011101.
- The write does not inherently change RAM[6].
- A later read of row 1 selects the new contents.
- The output data is 10011101, which equals 157 decimal.
- The address determines WHERE the information is stored; the data determines WHAT is stored.
Final answer: 157
State and memory · Problem 0068
RAM[8] initially stores 103. Write 194 there, then read the same location. What returns?
Try it on paper first. The worked answer is hidden below.
Reveal detailed solution →
- The machine models 16 byte-wide addresses: 0–15.
- Each location stores an eight-bit data word.
- At the start, RAM[8] contains 01100111 (103 unsigned).
- The CPU puts the four-bit address 1000 on the address lines.
- The decoder selects row 8, not row 13.
- Write-enable becomes active and the incoming data lines carry 11000010.
- The selected stored byte is replaced with 11000010.
- The write does not inherently change RAM[13].
- A later read of row 8 selects the new contents.
- The output data is 11000010, which equals 194 decimal.
- The address determines WHERE the information is stored; the data determines WHAT is stored.
Final answer: 194
State and memory · Problem 0069
RAM[15] initially stores 116. Write 231 there, then read the same location. What returns?
Try it on paper first. The worked answer is hidden below.
Reveal detailed solution →
- The machine models 16 byte-wide addresses: 0–15.
- Each location stores an eight-bit data word.
- At the start, RAM[15] contains 01110100 (116 unsigned).
- The CPU puts the four-bit address 1111 on the address lines.
- The decoder selects row 15, not row 4.
- Write-enable becomes active and the incoming data lines carry 11100111.
- The selected stored byte is replaced with 11100111.
- The write does not inherently change RAM[4].
- A later read of row 15 selects the new contents.
- The output data is 11100111, which equals 231 decimal.
- The address determines WHERE the information is stored; the data determines WHAT is stored.
Final answer: 231
State and memory · Problem 0070
RAM[6] initially stores 129. Write 12 there, then read the same location. What returns?
Try it on paper first. The worked answer is hidden below.
Reveal detailed solution →
- The machine models 16 byte-wide addresses: 0–15.
- Each location stores an eight-bit data word.
- At the start, RAM[6] contains 10000001 (129 unsigned).
- The CPU puts the four-bit address 0110 on the address lines.
- The decoder selects row 6, not row 11.
- Write-enable becomes active and the incoming data lines carry 00001100.
- The selected stored byte is replaced with 00001100.
- The write does not inherently change RAM[11].
- A later read of row 6 selects the new contents.
- The output data is 00001100, which equals 12 decimal.
- The address determines WHERE the information is stored; the data determines WHAT is stored.
Final answer: 12
State and memory · Problem 0071
RAM[13] initially stores 142. Write 49 there, then read the same location. What returns?
Try it on paper first. The worked answer is hidden below.
Reveal detailed solution →
- The machine models 16 byte-wide addresses: 0–15.
- Each location stores an eight-bit data word.
- At the start, RAM[13] contains 10001110 (142 unsigned).
- The CPU puts the four-bit address 1101 on the address lines.
- The decoder selects row 13, not row 2.
- Write-enable becomes active and the incoming data lines carry 00110001.
- The selected stored byte is replaced with 00110001.
- The write does not inherently change RAM[2].
- A later read of row 13 selects the new contents.
- The output data is 00110001, which equals 49 decimal.
- The address determines WHERE the information is stored; the data determines WHAT is stored.
Final answer: 49
State and memory · Problem 0072
RAM[4] initially stores 155. Write 86 there, then read the same location. What returns?
Try it on paper first. The worked answer is hidden below.
Reveal detailed solution →
- The machine models 16 byte-wide addresses: 0–15.
- Each location stores an eight-bit data word.
- At the start, RAM[4] contains 10011011 (155 unsigned).
- The CPU puts the four-bit address 0100 on the address lines.
- The decoder selects row 4, not row 9.
- Write-enable becomes active and the incoming data lines carry 01010110.
- The selected stored byte is replaced with 01010110.
- The write does not inherently change RAM[9].
- A later read of row 4 selects the new contents.
- The output data is 01010110, which equals 86 decimal.
- The address determines WHERE the information is stored; the data determines WHAT is stored.
Final answer: 86
State and memory · Problem 0073
RAM[11] initially stores 168. Write 123 there, then read the same location. What returns?
Try it on paper first. The worked answer is hidden below.
Reveal detailed solution →
- The machine models 16 byte-wide addresses: 0–15.
- Each location stores an eight-bit data word.
- At the start, RAM[11] contains 10101000 (168 unsigned).
- The CPU puts the four-bit address 1011 on the address lines.
- The decoder selects row 11, not row 0.
- Write-enable becomes active and the incoming data lines carry 01111011.
- The selected stored byte is replaced with 01111011.
- The write does not inherently change RAM[0].
- A later read of row 11 selects the new contents.
- The output data is 01111011, which equals 123 decimal.
- The address determines WHERE the information is stored; the data determines WHAT is stored.
Final answer: 123
State and memory · Problem 0074
RAM[2] initially stores 181. Write 160 there, then read the same location. What returns?
Try it on paper first. The worked answer is hidden below.
Reveal detailed solution →
- The machine models 16 byte-wide addresses: 0–15.
- Each location stores an eight-bit data word.
- At the start, RAM[2] contains 10110101 (181 unsigned).
- The CPU puts the four-bit address 0010 on the address lines.
- The decoder selects row 2, not row 7.
- Write-enable becomes active and the incoming data lines carry 10100000.
- The selected stored byte is replaced with 10100000.
- The write does not inherently change RAM[7].
- A later read of row 2 selects the new contents.
- The output data is 10100000, which equals 160 decimal.
- The address determines WHERE the information is stored; the data determines WHAT is stored.
Final answer: 160
State and memory · Problem 0075
RAM[9] initially stores 194. Write 197 there, then read the same location. What returns?
Try it on paper first. The worked answer is hidden below.
Reveal detailed solution →
- The machine models 16 byte-wide addresses: 0–15.
- Each location stores an eight-bit data word.
- At the start, RAM[9] contains 11000010 (194 unsigned).
- The CPU puts the four-bit address 1001 on the address lines.
- The decoder selects row 9, not row 14.
- Write-enable becomes active and the incoming data lines carry 11000101.
- The selected stored byte is replaced with 11000101.
- The write does not inherently change RAM[14].
- A later read of row 9 selects the new contents.
- The output data is 11000101, which equals 197 decimal.
- The address determines WHERE the information is stored; the data determines WHAT is stored.
Final answer: 197
State and memory · Problem 0076
RAM[0] initially stores 207. Write 234 there, then read the same location. What returns?
Try it on paper first. The worked answer is hidden below.
Reveal detailed solution →
- The machine models 16 byte-wide addresses: 0–15.
- Each location stores an eight-bit data word.
- At the start, RAM[0] contains 11001111 (207 unsigned).
- The CPU puts the four-bit address 0000 on the address lines.
- The decoder selects row 0, not row 5.
- Write-enable becomes active and the incoming data lines carry 11101010.
- The selected stored byte is replaced with 11101010.
- The write does not inherently change RAM[5].
- A later read of row 0 selects the new contents.
- The output data is 11101010, which equals 234 decimal.
- The address determines WHERE the information is stored; the data determines WHAT is stored.
Final answer: 234
State and memory · Problem 0077
RAM[7] initially stores 220. Write 15 there, then read the same location. What returns?
Try it on paper first. The worked answer is hidden below.
Reveal detailed solution →
- The machine models 16 byte-wide addresses: 0–15.
- Each location stores an eight-bit data word.
- At the start, RAM[7] contains 11011100 (220 unsigned).
- The CPU puts the four-bit address 0111 on the address lines.
- The decoder selects row 7, not row 12.
- Write-enable becomes active and the incoming data lines carry 00001111.
- The selected stored byte is replaced with 00001111.
- The write does not inherently change RAM[12].
- A later read of row 7 selects the new contents.
- The output data is 00001111, which equals 15 decimal.
- The address determines WHERE the information is stored; the data determines WHAT is stored.
Final answer: 15
State and memory · Problem 0078
RAM[14] initially stores 233. Write 52 there, then read the same location. What returns?
Try it on paper first. The worked answer is hidden below.
Reveal detailed solution →
- The machine models 16 byte-wide addresses: 0–15.
- Each location stores an eight-bit data word.
- At the start, RAM[14] contains 11101001 (233 unsigned).
- The CPU puts the four-bit address 1110 on the address lines.
- The decoder selects row 14, not row 3.
- Write-enable becomes active and the incoming data lines carry 00110100.
- The selected stored byte is replaced with 00110100.
- The write does not inherently change RAM[3].
- A later read of row 14 selects the new contents.
- The output data is 00110100, which equals 52 decimal.
- The address determines WHERE the information is stored; the data determines WHAT is stored.
Final answer: 52
State and memory · Problem 0079
RAM[5] initially stores 246. Write 89 there, then read the same location. What returns?
Try it on paper first. The worked answer is hidden below.
Reveal detailed solution →
- The machine models 16 byte-wide addresses: 0–15.
- Each location stores an eight-bit data word.
- At the start, RAM[5] contains 11110110 (246 unsigned).
- The CPU puts the four-bit address 0101 on the address lines.
- The decoder selects row 5, not row 10.
- Write-enable becomes active and the incoming data lines carry 01011001.
- The selected stored byte is replaced with 01011001.
- The write does not inherently change RAM[10].
- A later read of row 5 selects the new contents.
- The output data is 01011001, which equals 89 decimal.
- The address determines WHERE the information is stored; the data determines WHAT is stored.
Final answer: 89
State and memory · Problem 0080
RAM[12] initially stores 3. Write 126 there, then read the same location. What returns?
Try it on paper first. The worked answer is hidden below.
Reveal detailed solution →
- The machine models 16 byte-wide addresses: 0–15.
- Each location stores an eight-bit data word.
- At the start, RAM[12] contains 00000011 (3 unsigned).
- The CPU puts the four-bit address 1100 on the address lines.
- The decoder selects row 12, not row 1.
- Write-enable becomes active and the incoming data lines carry 01111110.
- The selected stored byte is replaced with 01111110.
- The write does not inherently change RAM[1].
- A later read of row 12 selects the new contents.
- The output data is 01111110, which equals 126 decimal.
- The address determines WHERE the information is stored; the data determines WHAT is stored.
Final answer: 126
State and memory · Problem 0081
RAM[3] initially stores 16. Write 163 there, then read the same location. What returns?
Try it on paper first. The worked answer is hidden below.
Reveal detailed solution →
- The machine models 16 byte-wide addresses: 0–15.
- Each location stores an eight-bit data word.
- At the start, RAM[3] contains 00010000 (16 unsigned).
- The CPU puts the four-bit address 0011 on the address lines.
- The decoder selects row 3, not row 8.
- Write-enable becomes active and the incoming data lines carry 10100011.
- The selected stored byte is replaced with 10100011.
- The write does not inherently change RAM[8].
- A later read of row 3 selects the new contents.
- The output data is 10100011, which equals 163 decimal.
- The address determines WHERE the information is stored; the data determines WHAT is stored.
Final answer: 163
State and memory · Problem 0082
RAM[10] initially stores 29. Write 200 there, then read the same location. What returns?
Try it on paper first. The worked answer is hidden below.
Reveal detailed solution →
- The machine models 16 byte-wide addresses: 0–15.
- Each location stores an eight-bit data word.
- At the start, RAM[10] contains 00011101 (29 unsigned).
- The CPU puts the four-bit address 1010 on the address lines.
- The decoder selects row 10, not row 15.
- Write-enable becomes active and the incoming data lines carry 11001000.
- The selected stored byte is replaced with 11001000.
- The write does not inherently change RAM[15].
- A later read of row 10 selects the new contents.
- The output data is 11001000, which equals 200 decimal.
- The address determines WHERE the information is stored; the data determines WHAT is stored.
Final answer: 200
State and memory · Problem 0083
RAM[1] initially stores 42. Write 237 there, then read the same location. What returns?
Try it on paper first. The worked answer is hidden below.
Reveal detailed solution →
- The machine models 16 byte-wide addresses: 0–15.
- Each location stores an eight-bit data word.
- At the start, RAM[1] contains 00101010 (42 unsigned).
- The CPU puts the four-bit address 0001 on the address lines.
- The decoder selects row 1, not row 6.
- Write-enable becomes active and the incoming data lines carry 11101101.
- The selected stored byte is replaced with 11101101.
- The write does not inherently change RAM[6].
- A later read of row 1 selects the new contents.
- The output data is 11101101, which equals 237 decimal.
- The address determines WHERE the information is stored; the data determines WHAT is stored.
Final answer: 237
State and memory · Problem 0084
RAM[8] initially stores 55. Write 18 there, then read the same location. What returns?
Try it on paper first. The worked answer is hidden below.
Reveal detailed solution →
- The machine models 16 byte-wide addresses: 0–15.
- Each location stores an eight-bit data word.
- At the start, RAM[8] contains 00110111 (55 unsigned).
- The CPU puts the four-bit address 1000 on the address lines.
- The decoder selects row 8, not row 13.
- Write-enable becomes active and the incoming data lines carry 00010010.
- The selected stored byte is replaced with 00010010.
- The write does not inherently change RAM[13].
- A later read of row 8 selects the new contents.
- The output data is 00010010, which equals 18 decimal.
- The address determines WHERE the information is stored; the data determines WHAT is stored.
Final answer: 18
State and memory · Problem 0085
RAM[15] initially stores 68. Write 55 there, then read the same location. What returns?
Try it on paper first. The worked answer is hidden below.
Reveal detailed solution →
- The machine models 16 byte-wide addresses: 0–15.
- Each location stores an eight-bit data word.
- At the start, RAM[15] contains 01000100 (68 unsigned).
- The CPU puts the four-bit address 1111 on the address lines.
- The decoder selects row 15, not row 4.
- Write-enable becomes active and the incoming data lines carry 00110111.
- The selected stored byte is replaced with 00110111.
- The write does not inherently change RAM[4].
- A later read of row 15 selects the new contents.
- The output data is 00110111, which equals 55 decimal.
- The address determines WHERE the information is stored; the data determines WHAT is stored.
Final answer: 55
State and memory · Problem 0086
RAM[6] initially stores 81. Write 92 there, then read the same location. What returns?
Try it on paper first. The worked answer is hidden below.
Reveal detailed solution →
- The machine models 16 byte-wide addresses: 0–15.
- Each location stores an eight-bit data word.
- At the start, RAM[6] contains 01010001 (81 unsigned).
- The CPU puts the four-bit address 0110 on the address lines.
- The decoder selects row 6, not row 11.
- Write-enable becomes active and the incoming data lines carry 01011100.
- The selected stored byte is replaced with 01011100.
- The write does not inherently change RAM[11].
- A later read of row 6 selects the new contents.
- The output data is 01011100, which equals 92 decimal.
- The address determines WHERE the information is stored; the data determines WHAT is stored.
Final answer: 92
State and memory · Problem 0087
RAM[13] initially stores 94. Write 129 there, then read the same location. What returns?
Try it on paper first. The worked answer is hidden below.
Reveal detailed solution →
- The machine models 16 byte-wide addresses: 0–15.
- Each location stores an eight-bit data word.
- At the start, RAM[13] contains 01011110 (94 unsigned).
- The CPU puts the four-bit address 1101 on the address lines.
- The decoder selects row 13, not row 2.
- Write-enable becomes active and the incoming data lines carry 10000001.
- The selected stored byte is replaced with 10000001.
- The write does not inherently change RAM[2].
- A later read of row 13 selects the new contents.
- The output data is 10000001, which equals 129 decimal.
- The address determines WHERE the information is stored; the data determines WHAT is stored.
Final answer: 129
State and memory · Problem 0088
RAM[4] initially stores 107. Write 166 there, then read the same location. What returns?
Try it on paper first. The worked answer is hidden below.
Reveal detailed solution →
- The machine models 16 byte-wide addresses: 0–15.
- Each location stores an eight-bit data word.
- At the start, RAM[4] contains 01101011 (107 unsigned).
- The CPU puts the four-bit address 0100 on the address lines.
- The decoder selects row 4, not row 9.
- Write-enable becomes active and the incoming data lines carry 10100110.
- The selected stored byte is replaced with 10100110.
- The write does not inherently change RAM[9].
- A later read of row 4 selects the new contents.
- The output data is 10100110, which equals 166 decimal.
- The address determines WHERE the information is stored; the data determines WHAT is stored.
Final answer: 166
State and memory · Problem 0089
RAM[11] initially stores 120. Write 203 there, then read the same location. What returns?
Try it on paper first. The worked answer is hidden below.
Reveal detailed solution →
- The machine models 16 byte-wide addresses: 0–15.
- Each location stores an eight-bit data word.
- At the start, RAM[11] contains 01111000 (120 unsigned).
- The CPU puts the four-bit address 1011 on the address lines.
- The decoder selects row 11, not row 0.
- Write-enable becomes active and the incoming data lines carry 11001011.
- The selected stored byte is replaced with 11001011.
- The write does not inherently change RAM[0].
- A later read of row 11 selects the new contents.
- The output data is 11001011, which equals 203 decimal.
- The address determines WHERE the information is stored; the data determines WHAT is stored.
Final answer: 203
State and memory · Problem 0090
RAM[2] initially stores 133. Write 240 there, then read the same location. What returns?
Try it on paper first. The worked answer is hidden below.
Reveal detailed solution →
- The machine models 16 byte-wide addresses: 0–15.
- Each location stores an eight-bit data word.
- At the start, RAM[2] contains 10000101 (133 unsigned).
- The CPU puts the four-bit address 0010 on the address lines.
- The decoder selects row 2, not row 7.
- Write-enable becomes active and the incoming data lines carry 11110000.
- The selected stored byte is replaced with 11110000.
- The write does not inherently change RAM[7].
- A later read of row 2 selects the new contents.
- The output data is 11110000, which equals 240 decimal.
- The address determines WHERE the information is stored; the data determines WHAT is stored.
Final answer: 240
State and memory · Problem 0091
RAM[9] initially stores 146. Write 21 there, then read the same location. What returns?
Try it on paper first. The worked answer is hidden below.
Reveal detailed solution →
- The machine models 16 byte-wide addresses: 0–15.
- Each location stores an eight-bit data word.
- At the start, RAM[9] contains 10010010 (146 unsigned).
- The CPU puts the four-bit address 1001 on the address lines.
- The decoder selects row 9, not row 14.
- Write-enable becomes active and the incoming data lines carry 00010101.
- The selected stored byte is replaced with 00010101.
- The write does not inherently change RAM[14].
- A later read of row 9 selects the new contents.
- The output data is 00010101, which equals 21 decimal.
- The address determines WHERE the information is stored; the data determines WHAT is stored.
Final answer: 21
State and memory · Problem 0092
RAM[0] initially stores 159. Write 58 there, then read the same location. What returns?
Try it on paper first. The worked answer is hidden below.
Reveal detailed solution →
- The machine models 16 byte-wide addresses: 0–15.
- Each location stores an eight-bit data word.
- At the start, RAM[0] contains 10011111 (159 unsigned).
- The CPU puts the four-bit address 0000 on the address lines.
- The decoder selects row 0, not row 5.
- Write-enable becomes active and the incoming data lines carry 00111010.
- The selected stored byte is replaced with 00111010.
- The write does not inherently change RAM[5].
- A later read of row 0 selects the new contents.
- The output data is 00111010, which equals 58 decimal.
- The address determines WHERE the information is stored; the data determines WHAT is stored.
Final answer: 58
State and memory · Problem 0093
RAM[7] initially stores 172. Write 95 there, then read the same location. What returns?
Try it on paper first. The worked answer is hidden below.
Reveal detailed solution →
- The machine models 16 byte-wide addresses: 0–15.
- Each location stores an eight-bit data word.
- At the start, RAM[7] contains 10101100 (172 unsigned).
- The CPU puts the four-bit address 0111 on the address lines.
- The decoder selects row 7, not row 12.
- Write-enable becomes active and the incoming data lines carry 01011111.
- The selected stored byte is replaced with 01011111.
- The write does not inherently change RAM[12].
- A later read of row 7 selects the new contents.
- The output data is 01011111, which equals 95 decimal.
- The address determines WHERE the information is stored; the data determines WHAT is stored.
Final answer: 95
State and memory · Problem 0094
RAM[14] initially stores 185. Write 132 there, then read the same location. What returns?
Try it on paper first. The worked answer is hidden below.
Reveal detailed solution →
- The machine models 16 byte-wide addresses: 0–15.
- Each location stores an eight-bit data word.
- At the start, RAM[14] contains 10111001 (185 unsigned).
- The CPU puts the four-bit address 1110 on the address lines.
- The decoder selects row 14, not row 3.
- Write-enable becomes active and the incoming data lines carry 10000100.
- The selected stored byte is replaced with 10000100.
- The write does not inherently change RAM[3].
- A later read of row 14 selects the new contents.
- The output data is 10000100, which equals 132 decimal.
- The address determines WHERE the information is stored; the data determines WHAT is stored.
Final answer: 132
State and memory · Problem 0095
RAM[5] initially stores 198. Write 169 there, then read the same location. What returns?
Try it on paper first. The worked answer is hidden below.
Reveal detailed solution →
- The machine models 16 byte-wide addresses: 0–15.
- Each location stores an eight-bit data word.
- At the start, RAM[5] contains 11000110 (198 unsigned).
- The CPU puts the four-bit address 0101 on the address lines.
- The decoder selects row 5, not row 10.
- Write-enable becomes active and the incoming data lines carry 10101001.
- The selected stored byte is replaced with 10101001.
- The write does not inherently change RAM[10].
- A later read of row 5 selects the new contents.
- The output data is 10101001, which equals 169 decimal.
- The address determines WHERE the information is stored; the data determines WHAT is stored.
Final answer: 169
State and memory · Problem 0096
RAM[12] initially stores 211. Write 206 there, then read the same location. What returns?
Try it on paper first. The worked answer is hidden below.
Reveal detailed solution →
- The machine models 16 byte-wide addresses: 0–15.
- Each location stores an eight-bit data word.
- At the start, RAM[12] contains 11010011 (211 unsigned).
- The CPU puts the four-bit address 1100 on the address lines.
- The decoder selects row 12, not row 1.
- Write-enable becomes active and the incoming data lines carry 11001110.
- The selected stored byte is replaced with 11001110.
- The write does not inherently change RAM[1].
- A later read of row 12 selects the new contents.
- The output data is 11001110, which equals 206 decimal.
- The address determines WHERE the information is stored; the data determines WHAT is stored.
Final answer: 206