12

Computer Science HL Paper 1 (May 2025, TZ2)

(a) Determine the value of variable X after execution of the following program statement:

X = recfn(5)

Show all your working. [5]

(b) Describe two basic stack operations. [4]

(c) Construct this algorithm in pseudocode. You may assume that the NUMBERS stack already contains real numbers. You must use the access methods of a stack. [6]