Note AcademyNote Academy

Computer Science · Oct / Nov 2019 · Paper 1 HL · Question 8

Adapt for 2027Tracing a while loop with a trace table is on the course; rewrite the IB pseudocode in Python or Java.

IBCS

As printed in the paper

The question as text

8. Construct a trace table for the following algorithm. K = 1 N = 1 M = 2 loop while K < 5 output(N,M) K = K + 1 N = N + 2 M = M * 2 end loop [5]

Read automatically from the paper; the printed page above is exact.

Show the answer and mark scheme

Make a free account to save your answers and see your weak topics and ask the AI why a wrong answer is wrong.