Question 12

AQA Computer Science June 2023 Paper 2 (8525/2)GCSE4 marks

On the specification

12.1
3.4 Computer systems
12.2
3.4 Computer systems
12.3
3.4 Computer systems
Question text

12.1 Figure 4 shows three programs (A, B, C) that add two numbers and output the result. box The programs are written in different programming languages. Figure 4 A B C x = 14 LDR R0, #14 0000 00001110 y = 3 LDR R1, #3 0001 00000011 z = x + y ADD R2, R0, R1 0110 00010000 OUTPUT(z) STR R2, 63 1010 10111111 OUT R2 1110 00000000 Identify the type of programming language used for each program shown in Figure 4 by writing A, B or C in the correct row of Table 2. You must only use each letter once. [2 marks] Table 2 A, B or C Assembly language High-level language Machine code 12.2 State one advantage of writing programs in assembly language instead of a high-level language. [1 mark] 12.3 Shade one lozenge to show which statement is true about program translators. [1 mark] A A compiler translates all the original program code before execution. B Compiled code still needs the original program code to execute. C Compiled code executes more slowly than code that is being interpreted. D Interpreters generate machine code directly. 4