Skip to main content
A-LevelComputer ScienceData types and structures9618/32 · May/June 2024 · Q59 Marks

Write this infix expression in Reverse Polish Notation (RPN): (7 – 2 + 8) / (9 – 5)

  1. (a)Write this infix expression in Reverse Polish Notation (RPN): (7 – 2 + 8) / (9 – 5)[2]
  2. (b)Evaluate this RPN expression: a d + a b + c – * when a = 6, b = 3, c = 7 and d = 9 Show the changing contents of the stack as the RPN expression is evaluated.[4]
  3. (c)Write this RPN expression in infix form: b a c – + d b + * c /[3]

Mark scheme

Marking points from the official mark scheme (May/June 2024). The mark or mark type is shown in brackets.

  1. [2] One mark 7 2 - 8 +
  2. [2] One mark 9 5 - /
  3. [2] Complete answer 7 2 - 8 + 9 5 - /
  4. [4] One mark per ring (Max 4)
  5. [4] (Stack trace diagram in MS: 9; 9,6; 15; 15,6; 15,6,3; 15,9; 15,9,7; 15,2; 30)
  6. [3] One mark per correct term (Max 3) (a - c + b)
  7. [3] * (d + b)
  8. [3] /c
  9. [3] Complete correct answer (((a - c) + b) * (d + b))/c Or (a - c + b) * (d + b)/c

Write your answer and get it marked

On Oracle Prep you can write or photograph your own answer and have it marked by AI against this mark scheme, with feedback on what you missed.

Sign up free →

About this question

Topic
Data types and structures, A-Level Computer Science (syllabus 9618). Structured question, 9 marks.
Source
A-Level Computer Science, May/June 2024 Paper 3 Variant 2, question 5.

Questions and mark schemes are from past examination papers and remain the copyright of the exam board. How Oracle Prep builds its content

Related Computer Science questions

© 2026 Oracle Prep