Algorithms and flowcharts – A Level Information Technology (9626)

30 questions · page 2 of 2 · Clear filters

0 / 0Answer a question to start your score.
Quick quiz (10)Saved 0
Advertisement
16
9626/13/O/N/23 · Question 8Oct/Nov 2023Paper 136 marks
Loading question…
Question text

8
The average (mean) of a set of 10 numbers is calculated by:
•
adding the numbers together to get a total
•
dividing the total by 10.
Juan has attempted to draw a flowchart of an algorithm which finds the average of 10 numbers.
He has made some mistakes and omitted to include some boxes.
Start
count ← 0
Input number
total ← total + number
yes
is count = 10?
no
average ← total / number
Suggest six improvements he should make to his flowchart.
1 …
…
2 …
…
3 …
…
4 …
…
5 …
…
6 …
… [6]

17
9626/13/O/N/23 · Question 9Oct/Nov 2023Paper 138 marks
Loading question…
Question text

9
A programmer is writing an algorithm in pseudocode to determine whether a number is a factor of
another number.
Y is a factor of X if the result of X/Y is a whole number.
In pseudocode INT(W) returns the whole number part of W.
If W is the same as INT(W) that means W is a whole number.
Complete the algorithm, including the missing first line, in pseudocode. Each THEN or ELSE
statement should be on a separate line to the action resulting from it. The algorithm uses:
•
W to store the result of X divided by Y
•
Z to store the value of INT(W).
The algorithm must output the values of Y and X together with an appropriate message if Y is a
factor of X or if Y is not a factor of X.
…
W←X/Y
Z=INT(W)
…
…
…
…
…
… [8]

18
9626/11/M/J/23 · Question 8May/June 2023Paper 118 marks
Loading question…
Question text

8
Complete this flowchart which will allow the input of ten numbers.
•
A number is even if the number divided by 2 is an integer.
•
If a number (N) is odd, it will be added to the odd total (OT).
•
If a number (N) is even, it will be added to the even total (ET).
•
Both these totals will be output after the tenth number has been processed.
Start
count
count + 1
ET
ET + N
Stop
[8]

Advertisement
19
9626/12/M/J/23 · Question 10May/June 2023Paper 126 marks
Loading question…
Question text

10 Gustav has started to write an algorithm using pseudocode. It will input 6 numbers, all less than
1000, and output the smallest value.
Complete the algorithm using pseudocode.
0
count
smallest 1000
WHILE count < 6
…
…
…
…
…
…
…
… [6]
Permission to reproduce items where third-party owned material protected by copyright is included has been sought and cleared where possible. Every
publisher will be pleased to make amends at the earliest possible opportunity.
To avoid the issue of disclosure of answer-related information to candidates, all copyright acknowledgements are reproduced online in the Cambridge
Assessment International Education Copyright Acknowledgements Booklet. This is produced for each series of examinations and is freely available to download
at www.cambridgeinternational.org after the live examination series.
Cambridge Assessment International Education is part of Cambridge Assessment. Cambridge Assessment is the brand name of the University of Cambridge

20
9626/13/M/J/23 · Question 6May/June 2023Paper 138 marks
Loading question…
Question text

6
A computer-controlled traffic light system controls the flow of motor vehicles and pedestrians.
Describe the inputs, processing and outputs involved in this system.
…
…
…
…
…
…
…
…
…
…
…
…
…
…
…
…
…
…
…
… [8]

21
9626/13/M/J/23 · Question 11May/June 2023Paper 138 marks
Loading question…
Question text

11
In Ruritania these are the tax rules.
•
People who earn up to $10 000 pay no tax.
•
People who earn between $10 000 and $40 000 pay 20% tax on their earnings above $10 000.
•
People who earn more than $40 000:
pay $6 000 ($30 000 × 20%)
and pay 40% tax on their earnings above $40 000.
Complete this flowchart which shows how the net wage (the money earned after tax is paid) is
calculated and is output for an individual in Ruritania.
Start
Input
earnings
Stop
[8]
Permission to reproduce items where third-party owned material protected by copyright is included has been sought and cleared where possible. Every
publisher will be pleased to make amends at the earliest possible opportunity.
To avoid the issue of disclosure of answer-related information to candidates, all copyright acknowledgements are reproduced online in the Cambridge
Assessment International Education Copyright Acknowledgements Booklet. This is produced for each series of examinations and is freely available to download
at www.cambridgeinternational.org after the live examination series.
Cambridge Assessment International Education is part of Cambridge Assessment. Cambridge Assessment is the brand name of the University of Cambridge

22
9626/12/F/M/23 · Question 4Feb/March 2023Paper 128 marks
Loading question…
Question text

4
Mark has a small glasshouse. He lives in a warm country where plants can die if they are left
without water for too long. The glasshouse has a microprocessor controlled sprinkler system and
a moisture sensor in the soil.
Complete this flowchart to show the processing required to control the level of moisture in the soil
of the glasshouse. You may assume that a pre-set value, dry, has already been input so that the
system can test if the amount of moisture in the soil has reached or fallen below a certain level.
The user activates the microprocessor system by pressing a switch.
(a) Complete the flowchart which inputs the moisture reading in the glasshouse and switches the
sprinkler on and off according to this value. It also checks if the sprinkler is already on or off
before attempting to switch it on or off.
Start
Is the
system
activated?
Stop
is mlevel >
dry?
is sprinkler
on?
[6]
(b) Flowcharts often contain subroutines.
(i)
Draw the symbol used to represent a subroutine in a flowchart.
[1]
(ii)
State what you would expect to see in the first box of a subroutine.
…
… [1]

23
9626/12/O/N/22 · Question 9Oct/Nov 2022Paper 1210 marks
Loading question…
Question text

9
A programmer is writing an algorithm in pseudocode to represent a company’s payroll system.
The system calculates a worker’s wages before tax by multiplying the number of hours worked by
the rate of pay per hour. A procedure within the main algorithm representing this could be:
PROCEDURE BeforeTax(Hours, Rate)
Hours * Rate
WagesBeforeTax
ENDPROCEDURE
There are two stages involved in calculating the wages after tax:
•
the amount of tax paid by the worker is calculated by multiplying the WagesBeforeTax by the
rate of tax (35%);
•
the amount of tax paid is then subtracted from the WagesBeforeTax.
(a) Write a procedure for calculating the wages after tax, assuming the value of WagesBeforeTax
is passed to it.
…
…
…
…
…
…
…
… [4]
(b) The programmer’s algorithm will use the BeforeTax() procedure and the procedure created
in part (a) to calculate and output the wage after tax for each worker.
Complete the algorithm. The statements have been numbered to help you.
0
1
count
2
INPUT NumberOfWorkers
3
REPEAT
…
4
…
5
…
6
…
7
…
8
UNTIL … [6]
9

Advertisement
24
9626/13/O/N/22 · Question 8Oct/Nov 2022Paper 136 marks
Loading question…
Question text

8
A teacher wishes to produce a computer program to output the grades awarded for all of her
students.
If a student scores:
•
more than 60 marks, they are awarded a grade A
•
50 – 60 marks, they are awarded a grade B
•
40 – 49 marks, they are awarded a grade C
•
below 40 marks, they are awarded a grade D.
The teacher has written the following algorithm before writing the program. Unfortunately, there
are errors and some lines have been left out (omitted). She has, however, managed to include the
correct number of ELSE statements.
1.
INPUT mark
2.
IF mark > 60
3.
THEN
4.
PRINT "A"
5.
ELSE
6.
IF mark < 50
7.
THEN
8.
PRINT B
9.
ELSE
10.
IF mark >= 40
11.
THEN
12.
PRINT "C"
13.
ELSE
14.
PRINT "D"
15.
ENDIF
16.
ENDIF
Identify each error or omission and how these could be corrected. Line numbers have been
included to help you.
…
…
…
…
…
…
…
…
…
…
…
…
… [6]

25
9626/12/M/J/22 · Question 7May/June 2022Paper 127 marks
Loading question…
Question text

7
Josefine has started to draw a flowchart which inputs 10 numbers and outputs the largest value.
Complete the flowchart by filling in the empty boxes and by placing yes and no as appropriate in
the diagram.
Start
count
0
max
0
Input
number
Stop
[7]

26
9626/13/M/J/22 · Question 8May/June 2022Paper 137 marks
Loading question…
Question text

8
A microprocessor-controlled car park barrier is used to allow cars to enter a car park. When a
car approaches the barrier, the barrier automatically rises to allow the car to enter. It does not
lower until the car is safely clear of the barrier system. There is a light sensor and light beam
source immediately before the barrier. No tickets are issued by the system. The system operates
continuously while it is switched on.
Complete this pseudocode algorithm to describe the processing involved. Your pseudocode
algorithm should include IF…THEN statements.
REPEAT
INPUT reading from induction loop
…
…
…
…
…
…
…
…
…
…
…
…
…
… [7]

27
9626/13/M/J/22 · Question 11May/June 2022Paper 137 marks
Loading question…
Question text

11
Complete the flowchart below to add up 6 numbers.
Use the variable total to store the sum of the numbers and the variable count to control the number
of times the loop is repeated.
Start
INPUT
number
Stop
[7]
Permission to reproduce items where third-party owned material protected by copyright is included has been sought and cleared where possible. Every
publisher will be pleased to make amends at the earliest possible opportunity.
To avoid the issue of disclosure of answer-related information to candidates, all copyright acknowledgements are reproduced online in the Cambridge
Assessment International Education Copyright Acknowledgements Booklet. This is produced for each series of examinations and is freely available to download
at www.cambridgeinternational.org after the live examination series.
Cambridge Assessment International Education is part of Cambridge Assessment. Cambridge Assessment is the brand name of the University of Cambridge

28
9626/12/F/M/22 · Question 4Feb/March 2022Paper 124 marks
Loading question…
Question text

4
Computerised weather stations are used to monitor a number of analogue atmospheric variables.
Describe how three of these variables are collected and what needs to happen to the data before
it can be used by a computer.
…
…
…
…
…
…
…
…
…
… [4]

Advertisement
29
9626/12/F/M/22 · Question 7Feb/March 2022Paper 128 marks
Loading question…
Question text

7
The average (mean) of a set of numbers can be found by adding the numbers together and
dividing the resulting total by how many numbers there are in the set.
Write an algorithm in pseudocode to enter and find the average of a set of numbers using a
REPEAT…UNTIL loop. Your algorithm must work for different sets of numbers.
…
…
…
…
…
…
…
…
…
…
…
…
…
… [8]

30
9626/11/M/J/21 · Question 2May/June 2021Paper 1110 marks
Loading question…
Question text

2
There are a number of different ways that data can be directly input to a computer.
(a) Tick the most accurate statement referring to the inputting of text using an Optical Character
Reader.
✓
It is a lot slower to enter large amounts of text than an inexperienced user typing
it in
It can be used to read ordinary handwriting
It is always completely accurate, with no mistakes being made
It is more expensive to scan the text than to pay someone to type in the text
[1]
(b) Tick the most accurate statement referring to the inputting of examination paper answers
using an Optical Mark Reader.
✓
It is very suitable for entering text
It can read marks made on an otherwise blank piece of paper
It is much more accurate than data being keyed in by a person
If the marks are not in a dark enough pencil, they are still always read correctly
[1]
(c) Evaluate, by weighing up the advantages and disadvantages, the use of MICR for inputting
text.
…
…
…
…
…
…
…
…
…
…
…
…
…
…
…
…
…
…
… [8]

Advertisement