Tip: Choose Save as PDF in the print dialog to download. Use A4 paper size.
Shade in the A or B circle for each question.
Draw a line connecting each item on the left to its match on the right.
| Left column | Right column | |
|---|---|---|
| 1Row 3 fails, column 5 fails | AThe row and column numbers are swapped. The error is at row 2, column 4, where the failed row and failed column cross. | |
| 2Flip bit at row 3, column 5: 1 -> 0 | BThe changed bit is at the crossing point of row 3 and column 5 | |
| 3The row and the column that both fail their parity check cross at the bit that has changed | CA failed row alone does not locate the bit. You also need the failed column, and the changed bit is where they cross. | |
| 4A parity block can correct a single-bit error, which a single parity bit cannot | DCorrects a single-bit error once the changed bit has been found | |
| 5Only row 2 fails, so the error is the whole of row 2 | EError at row 2, column 4 is 0 -> flip it to 1 | |
| 6Row 2 and column 4 fail, so the error is at row 4, column 2 | FRow 2 odd + column 4 odd -> error at row 2, column 4 |
Complete each line of code by filling in the missing parts.
Shade in the letter of the line that contains an error.
failed row and column — In a parity block, the row and the column that both fail their parity check cross at the bit that changed. Flip that bit to correct a single-bit error.IF rowSum MOD 2 = 1 THEN
rowFailed ← TRUE
ENDIFbadBit ← block[failedRow][failedCol]block[r][c] ← 1 - block[r][c]IF rowFailed AND colFailed THEN
flip(row, col)
ENDIFFOR col ← 0 TO 7
IF colFailed[col] THEN errorCol ← col
NEXT col