Question
Option 2 : grant the request because the system remains safe and P1 can finish first / अनुरोध स्वीकार करना चाहिए क्योंकि सिस्टम सुरक्षित रहता है और P1 सबसे पहले समाप्त हो सकता है
Detailed Solution
सही उत्तर grant the request because the system remains safe and P1 can finish first / अनुरोध स्वीकार करना चाहिए क्योंकि सिस्टम सुरक्षित रहता है और P1 सबसे पहले समाप्त हो सकता है है।
Question:
A system with 3 resource types has Available = (3,3,2). Allocation and Max matrices are: P0: Alloc(0,1,0) Max(7,5,3); P1: Alloc(2,0,0) Max(3,2,2); P2: Alloc(3,0,2) Max(9,0,2); P3: Alloc(2,1,1) Max(2,2,2); P4: Alloc(0,0,2) Max(4,3,3). P1 now requests (1,0,2). Applying the Banker's algorithm, the system should ___ / 3 संसाधन प्रकारों वाले सिस्टम में Available = (3,3,2) है। Allocation और Max मैट्रिक्स हैं: P0: Alloc(0,1,0) Max(7,5,3); P1: Alloc(2,0,0) Max(3,2,2); P2: Alloc(3,0,2) Max(9,0,2); P3: Alloc(2,1,1) Max(2,2,2); P4: Alloc(0,0,2) Max(4,3,3)। P1 अब (1,0,2) का अनुरोध करता है। Banker's एल्गोरिद्म लागू करने पर सिस्टम को ___
Correct Answer: grant the request because the system remains safe and P1 can finish first / अनुरोध स्वीकार करना चाहिए क्योंकि सिस्टम सुरक्षित रहता है और P1 सबसे पहले समाप्त हो सकता है
P1's Need = Max - Alloc = (1,2,2). Request (1,0,2) is within both Need and Available (3,3,2). After granting, Available = (2,3,0) and P1's new Need = (0,2,0), which fits Available, so P1 can finish first; the state remains safe. / P1 की Need = Max - Alloc = (1,2,2)। अनुरोध (1,0,2) Need और Available (3,3,2) दोनों के भीतर है। स्वीकृति के बाद Available = (2,3,0) और P1 की नई Need = (0,2,0), जो Available में समाती है, अतः P1 सबसे पहले समाप्त हो सकता है; अवस्था सुरक्षित रहती है।