Question 3

OCR Computer Science June 2019 Paper 1A level9 marks

On the specification

(a)
1.2 Software and software development
(b)
1.2 Software and software development
(c)
1.1 The characteristics of contemporary processors, input, output and storage devices
(d)
1.2 Software and software development
(e)
1.2 Software and software development
Question text

3 A program written in the Little Man Computer instruction set is given below. INP STA num loop LDA total ADD num STA total LDA count ADD one STA count SUB num BRZ end BRA loop end LDA total OUT HLT one DAT 1 num DAT 0 count DAT 0 total DAT 0 (a) State what the program outputs are for the following inputs. Input Output 1 2 3 [3] (b) State what the purpose of the program is. [1] (c) Explain which registers are used and their values when the line STA count is executed and the accumulator is holding the value 9. The label count refers to memory location 16. [2] Whilst the line STA count is being executed, the CPU receives a signal from another process, requiring its attention. (d) State the name for the signal received by the CPU. [1] (e) The code uses direct addressing. Describe one other mode of addressing. [2]