Past-paper question · 2015 October-November · Paper 22 · Q1

Question 1 2015 · October-November · Paper 22 · 5 marks

Original past-paper question for 1
Original past-paper question for 1
Reveal official mark-scheme answer Official mark-scheme answer for 1

Official answer for Question 1

(i)

2

[1]

(ii)

7.5

[1]

(iii)

FALSE

[1]

(iv)

TRUE

[1]

(v)

ERROR

[1]

Mark scheme 9608_w15_ms_22.pdf →

Show text version of question

Question 1

Computer programs have to evaluate expressions.

Study the sequence of pseudocode statements.

Give the value assigned to each variable.

The statement may generate an error. If so, write ERROR.

The & operator is used to concatenate strings.

DECLARE N1 : INTEGER DECLARE N2 : INTEGER DECLARE Answer : REAL DECLARE Found : BOOLEAN DECLARE IsValid : BOOLEAN N1 ← 3 N2 ← 9 Answer ← (N1 + N2) / 6 Answer ← 3 * (N1 – 2) + N2 / 2 IsValid ← (N1 > N2) AND (N2 = 9) Found ← FALSE

IsValid ← (N1 > N2 / 2) OR (Found = FALSE) Answer ← "1034" & " + " & "65"

(i)

Answer ..............................................................................................................................

[1]

(ii)

Answer ..............................................................................................................................

[1]

(iii)

IsValid ...........................................................................................................................

[1]

(iv)

IsValid ...........................................................................................................................

[1]

(v)

Answer ..............................................................................................................................

[1]

To avoid the issue of disclosure of answer-related information to candidates, all copyright acknowledgements are reproduced online in the Cambridge International Examinations Copyright Acknowledgements Booklet. This is produced for each series of examinations and is freely available to download at www.cie.org.uk after the live examination series.

Question 3

Topic relevance

Why this question appears here

82% assigned-topic match · Data types and structures › Data types and records

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 9608_w15_qp_22.pdf

Keep practising this topic