598 views
0 0 votes
Suppose we want to synchronize two concurrent processes P and Q using binary semaphores S, T and U:

                    Process P:                                           Process Q:

                        P(S)                                                     W:

                        P(T)                                                     X:

                        P(U)                                                    Y:

                      Print ‘a’                                             Print ‘a’;

                      Print ‘b’                                            Print ‘b’;

                        V(S)                                                    A:

                        V(T)                                                    B:

                        V(U)                                                    C:

What should be written at W to avoid deadlock?

(a) P(T)                                                                       (b) P(U)

(c) P(S)                                                                       (d) Not possible to avoid deadlock

Please log in or register to answer this question.

Position:
Show:

Related questions

0 0 votes
1 answers 1 answer
574
574 views
KushagrJ asked Jul 30, 2023
574 views
For GATE, 2024, I am going to solve previous years’ papers as mock tests, in order to get the proper feel of the actual exam.When going through the syllabi for previous y...
0 0 votes
0 0 answers
1.2k
1.2k views
vg653 asked Dec 18, 2018
1,210 views
The Minimum number of possible edges in an undirected graph with n vertices and k components is ______
0 0 votes
0 0 answers
712
712 views
abhishek1995_cse asked Dec 2, 2018
712 views
Q1. https://gateoverflow.in/3375/gate2008-it-64Q2. https://gateoverflow.in/8481/gate2015-3-28In Q1 the rtt is doubled while calculating but in Q2 rtt is not doubled. w...
0 0 votes
0 0 answers
537
537 views
sripo asked Nov 9, 2018
537 views
Is it a good idea to solve previous years gate questions multiple times as with time you get more awareness of certain topics and you can use different approaches to solv...