Back to the 2024 paper

Module 3: Inter-process Communication

20242m

In Peterson's solution for two processes, which condition ensures mutual exclusion?
(i) Both processes wait infinitely
(ii) Only one process enters the critical section at a time
(iii) Both processes enter the critical section together
(iv) The process with a higher ID always wins

Worked SolutionAI Assisted

Answer: (ii) Only one process enters the critical section at a time

Peterson's flags+turn ensures mutual exclusion, progress, bounded waiting for 2 processes without hardware support.

Similar questions

AI LearningWeb Platform

Coursify — Personal AI Course Generator

Struggling with a difficult subject or concept? Turn any engineering topic into a structured course with interactive lessons, quizzes, and research-backed explanations.