The Gateway to Computer Science Excellence
+2 votes

1 point

The variable turn can have values 0 or 1

  Void Process (i)




          //Non-critical section

           While (turn!=i);

                //     Critical section

            turn = j;



The above code does not provide

 1. Mutual exclusion

 2. Progress

 3. Bounded wait

 4. None of these

in Operating System by (255 points) | 81 views

1 Answer

0 votes

1.ME-true ,because only turn can have value either 0 or 1 which ensure ME

2-Progress-False, because let suppose  turn =1 for process j but j dont want to critical section whereas i wants to enter but it has to wait for j

3.Bounded Waiting-true, Because no other can enter into critical section more than once continuously as turn value is changing after critical section

so answer is B

by (157 points)
Quick search syntax
tags tag:apple
author user:martin
title title:apple
content content:apple
exclude -tag:apple
force match +apple
views views:100
score score:10
answers answers:2
is accepted isaccepted:true
is closed isclosed:true
50,833 questions
57,709 answers
107,630 users