Write this Reverse Polish Notation (RPN) in infix form: 5 2 + 9 3 - / 3 *
- (a)Write this Reverse Polish Notation (RPN) in infix form: 5 2 + 9 3 - / 3 *[3]
- (b)Write this infix expression in RPN: ((7 + 3) - (2 * 8)) / 6[2]
- (c)Evaluate this RPN expression: a b - c d + * e / when a = 17, b = 5, c = 7, d = 3 and e = 10 Show the changing contents of the stack as the RPN expression is evaluated.[4]
Mark scheme
Marking points from the official mark scheme (May/June 2024). The mark or mark type is shown in brackets.
- [3] 5(a) One mark per correct term (Max 3)
- 5(a) (5 + 2)
- 5(a) / (9 - 3)
- 5(a) * 3
- 5(a) Complete correct answer ((5 + 2) / (9 - 3)) * 3
- [2] 5(b) One mark 7 3 +
- 5(b) One mark 2 8 * - 6 /
- 5(b) Complete answer 7 3 + 2 8 * - 6 /
- [4] 5(c) One mark per ring (Max 4)
- 5(c) Stack contents: [17]
- 5(c) Stack contents: [17, 5]
- 5(c) Stack contents: [12]
- 5(c) Stack contents: [12, 7]
- 5(c) Stack contents: [12, 7, 3]
- 5(c) Stack contents: [12, 10]
- 5(c) Stack contents: [120]
- 5(c) Stack contents: [120, 10]
- 5(c) Stack contents: [12]
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 →