The following program consists of 3 concurrent processes and 3 binary…

GATE · 2010 · CS · Computer Science & IT

The following program consists of 3 concurrent processes and 3 binary semaphores. The semaphores are initialized as S0 = 1, S1 = 0, S2 = 0.

image.png

How many times will process P0 print ‘0’?

  1. A.

    At least twice

  2. B.

    Exactly twice

  3. C.

    Exactly thrice

  4. D.

    Exactly once

Attempted by 294 students.

Sign up free to check your answer

Sign up free

Explore the full course: Gate Guidance By Sanchit Sir

Loading lesson…