CPU Scheduling

Answer & solution
Answer: B (no official key was published)
1. At time 2 the first process has 8 units remaining, less than the new 20. At time 6 it has 4 remaining, less than 30.
2. It therefore runs 0–10, followed by the 20-unit process 10–30 and the 30-unit process 30–60. Excluding initial dispatch and final exit leaves two process switches, B.
3. Teaching check: Draw the CPU timeline 0–10:P1, 10–30:P2, 30–60:P3. An arrival is not automatically a preemption: compare its burst with the current remaining time. Only the changes P1→P2 and P2→P3 count under the exclusions in the question.