Past-paper question · 2025 May-June · Paper 41 · Q3(e)(ii)

Question 3(e)(ii) 2025 · May-June · Paper 41 · 1 mark

Original past-paper question for 3(E)(II)
Original past-paper question for 3(E)(II)
Original past-paper question for 3(E)(II)
Original past-paper question for 3(E)(II)
Original past-paper question for 3(E)(II)
Original past-paper question for 3(E)(II)
Reveal official mark-scheme answer Official mark-scheme answer for 3(E)(II)

Official answer for Question 3

Part (e)

(ii)

✓
Output of

Question 1

Question 5

Question 7

Question 10

Question 15

Question 20

Mark scheme 9618_s25_ms_41.pdf →

Show text version of question

Question 3

Part (e)

(ii)

Question 3

A program stores data in a binary tree that is designed using Object‑Oriented Programming

(OOP).

The tree stores data in ascending numerical order, for example:

Question 30

20 45

1 21 33 63

The class Node stores data about the nodes.

Node NodeData : Integer stores the node’s integer data

LeftNode : Node stores the node that is stored to the left of the current node, or a null value if there is no node to the left

RightNode : Node stores the node that is stored to the right of the current node, or a null value if there is no node to the right Constructor() initialises NodeData to its parameter value; initialises LeftNode and RightNode to a null value

GetLeft() returns LeftNode

GetRight() returns RightNode

GetData() returns NodeData

SetLeft() takes an object of type Node as a parameter and stores it in LeftNode

SetRight() takes an object of type Node as a parameter and stores it in RightNode

Question 7

(ii)

Test your program.

Take a screenshot of the output(s).

Save your program.

Copy and paste the screenshot into part 3(e)(ii) in the evidence document.

[1]

Question 10

Question 11

Question 12

Permission to reproduce items where third‑party owned material protected by copyright is included has been sought and cleared where possible. Every 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.

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 Local Examinations Syndicate (UCLES), which is a department of the University of Cambridge.

Topic relevance

Why this question appears here

71% assigned-topic match · Programming › Constructs

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 9618_s25_qp_41.pdf

Keep practising this topic