(a) A byte uses even parity, with the most significant bit as the parity bit and the 7-bit ASCII code for 'C' (1000011) in the other bits. State the byte stored. [1]
(b) The byte 10110010 is received. A student says: "Even parity checking passed, so the byte must be correct." Explain why the student may be wrong. [2]
(c) The first 12 digits of an ISBN-13 are 978140883219. Calculate the check digit. Digits are multiplied alternately by 1 and 3 starting with 1, the products are summed, and the check digit makes the total a multiple of 10. [3]
- 11000011 (parity bit 1 because 1000011 has three 1s)(1)
- Parity can only detect an odd number of bit errors (accept: it only detects single-bit errors)(1)
- If two (or any even number of) bits are flipped, the number of 1s stays even, so the byte would pass the check even though it is corrupted (accept a worked example, e.g. two bits of the original changed)(1)
- Weighted sum: 9×1+7×3+8×1+1×3+4×1+0×3+8×1+8×3+3×1+2×3+1×1+9×3 = 114(1)
- Next multiple of 10 is 120 (or 10 − (114 mod 10))(1)
- Check digit 6 (correct check digit with no working scores 3 marks)(1)
- Answer: (a) 11000011 (b) parity cannot detect an even number of bit errors, so a corrupted byte can still pass (c) 6
- Examiner tip: Parity detects an odd number of flipped bits only; never say it "corrects" errors.