9618/12/M/J/24 question 7: worked solution (May/June 2024, paper 12)
Show as plain textHide plain text
Cambridge AS Level Computer Science 9618 · 1.1 Data Representation Worked solution from the Information representation Paper 1 Theory Fundamentals booklet, Part 1 of 3. Q16 9618/12/M/J/24 original Q7 Structured · 6 marks Worked solution (a) Convert each size to bytes: 3300 kibibytes = 3300 × 1024 = 3 379 200 bytes 0.3 megabytes = 300 000 bytes 3 mebibytes = 3 × 1 048 576 = 3 145 728 bytes 3300 kilobytes = 3 300 000 bytes Tick 3300 kibibytes . [1] (b) Write both numbers in 8-bit binary: 100 = 0110 0100 and 10 = 0000 1010. [1] Subtract by two's complement: invert 0000 1010 and add 1 to get −10 = 1111 0110, then add it to 100. 01100100 + 11110110 ---------- (1)01011010 Method shown, either adding −10 or direct subtraction with borrows [1] Ignore the carry out. Answer 0101 1010 (90) [1] (c) C = 12, 0 = 0, F = 15. Working: (12 × 16²) + (0 × 16) + 15 = 3072 + 15, or 1100 0000 1111 = 2048 + 1024 + 8 + 4 + 2 + 1 [1] 3087 [1] KEY IDEA Change every size to bytes to compare them, and subtract in binary by adding the two's complement. TOTAL 6 marks Official mark scheme VIDEO ▶ Starts at Q7 (1:07:05) Starts at Q7 (1:07:05) · by Pseudocode Pro. Tap the picture to open it on YouTube.