Question 7(d)(iii) 2012 · May-June · Paper 33 · 45 marks
Question 7
Part (d)
(iii)
Question 7
MAURITIUS 7
250 250
An algorithm is required to delete a value from the linked list. Examiner's Use The algorithm will use the following variables:
Identifier Data Type Description Current INTEGER Array index for the current capital
Previous INTEGER Array index for the previous capital
The following diagram shows the first three capitals in the linked list. We are about to delete CANBERRA. The list has been searched from the HeadPointer position until the capital to be deleted, CANBERRA, is found.
HeadPointer 5
BERLIN 3 CANBERRA 7 DHAKA 9 5 3 7 Etc.
Previous = 5 Current = 3
Describe the steps in the algorithm to delete CANBERRA from the linked list. (Do not attempt to write the complete algorithm.)
Question 10
4 Expressions can be written in either infix or reverse Polish notation. For Examiner's Use
Part (a)
Evaluate this reverse Polish expression:
9 6 – 5 *
Part (b)
Write the following infix expressions in reverse Polish.
(iii)
The reverse Polish expression 4 7 * 2 + 5 / is to be evaluated using a stack. For
The first available location on the stack is 1. Examiner's Use
Show how the contents of the stack change as this expression is evaluated.
Question 5
Question 4
Question 3
Question 2
Question 1
Question 12
Question 5
Part (a)
Define what is meant by the term computer simulation. For
Examiner's Use
Part (b)
Give two reasons why a computer system is particularly suited to carrying out a
simulation.
Question 1
Question 2
Part (c)
A new road has been built which crosses an existing road at right angles. A new set of
traffic control lights is to be installed to control the traffic flows on the existing and new road.
Identify three variables which need to be controlled by the software simulation of the operation of the traffic lights.
Question 1
Question 2
Question 3
Part (d)
The values input to the simulation will affect the outputs produced.
Give one example for this traffic control light scenario of a change to an input which will directly affect the output.
Input change
Effect on the output
Question 13
6 The table shows the assembly language instructions for a processor which has one general For purpose register – the Accumulator. Examiner's Use
Instruction Explanation Op Code Operand
LDD <address> Load using direct addressing
STO <address> Store the contents of the Accumulator at the given address
LDI <address> Load using indirect addressing
LDX <address> Load using indexed addressing
INC Add 1 to the contents of the Accumulator
END End the program and return to the operating system
Part (a)
Write on the diagram to explain the assembly language instruction shown below.
Show the contents of the Accumulator after the execution of the instruction.
LDD 66 Main memory 60 0110 0000 61 0100 0000 Accumulator 62 1111 1110 63 1111 0000 64 0101 1101 65 0001 0001 66 1010 1000 67 1100 0001
200 1001 1111
Part (b)
Write on the diagram to explain the assembly language instruction shown.
Show the contents of the Accumulator after the execution of the instruction.
LDI 61 Main memory 60 0110 0000 61 0100 0000 Accumulator 62 1111 1110 63 1111 0000 64 0101 1101 65 0001 0001 66 1010 1000 67 1100 0001
200 1001 1111
Question 14
Part (c)
Trace this assembly language program using the given trace table. The first instruction For
of the program is loaded into main memory at address 200. Examiner's Use
200 LDD 208 201 INC 202 STO 208 203 LDD 207 204 INC 205 STO 207 206 END 207 16 208 150
Memory Address Accumulator 207 208 16 150
Part (d)
Explain the relationship between assembly language instructions and machine code
instructions.
Question 15
Question 7
Part (a)
Explain what is meant by an interrupt. For
Examiner's Use
Part (b)
An operating system uses interrupts which have priorities.
Describe the sequence of steps which would be carried out by the interrupt handler software when an interrupt is received and serviced.
Question 16
Part (c)
Modern personal computer operating systems support multi-tasking. For
One of the modules of such an operating system will be for memory management. Examiner's Use
Describe two different strategies which could be used to manage the available main memory.
Question 1
Question 2
Part (d)
Once a process finishes and memory becomes available, the scheduler will decide
which process/job is to be loaded next.
State three attributes of a process which are used to assess which job will be the next to be loaded into main memory.
Question 1
Question 2
Question 3
reasonable effort has been made by the publisher (UCLES) to trace copyright holders, but if any items requiring clearance have unwittingly been included, the publisher will be pleased to make amends at the earliest possible opportunity.
University of Cambridge International Examinations is part of the Cambridge Assessment Group. Cambridge Assessment is the brand name of University of Cambridge Local Examinations Syndicate (UCLES), which is itself a department of the University of Cambridge.
Reveal official mark-scheme answer
The answer for this question is in the official mark scheme: open the mark scheme.
Why this question appears here
91% assigned-topic match · System software › Operating systems
Topic-match percentages estimate how closely each question fits the selected syllabus topic. They are a guide for choosing stricter or broader practice.
Permanent source page: Educate A Change · From 9691_s12_qp_33.pdf
