Computer AwarenessVery hardIBPS SO IT Officer
A system has 12 tape drives. P0 holds 5 (maximum need 10), P1 holds 2 (maximum 4) and P2 holds 2 (maximum 9). Under the Banker's algorithm, which is a safe sequence?
- A. <P0, P1, P2>
- B. <P2, P1, P0>
- C. <P1, P0, P2>
- D. No safe sequence exists
Correct answer: C. <P1, P0, P2>
Free = 12 − 9 = 3. P1 needs 2, finishes, free 5; P0 needs 5, finishes, free 10; P2 needs 7, finishes. P0 cannot go first (needs 5 with only 3 free), and P2 cannot run before P0.
हिंदी में
एक प्रणाली में 12 टेप ड्राइव हैं। P0 के पास 5 हैं (अधिकतम आवश्यकता 10), P1 के पास 2 (अधिकतम 4) और P2 के पास 2 (अधिकतम 9)। बैंकर के एल्गोरिदम में कौन-सा सुरक्षित अनुक्रम है?
- A. <P0, P1, P2>
- B. <P2, P1, P0>
- C. <P1, P0, P2>
- D. कोई सुरक्षित अनुक्रम नहीं है
उत्तर: C. खाली = 12 − 9 = 3। P1 को 2 चाहिए, वह पूरा होता है, खाली 5; P0 को 5 चाहिए, वह पूरा होता है, खाली 10; P2 को 7 चाहिए, वह पूरा होता है। P0 पहले नहीं जा सकता (3 खाली होने पर 5 चाहिए), और P2 P0 से पहले नहीं चल सकता।
More Computer Awareness questions
- Four processes share identical units of one resource, and each may need up to 3 units at once. What is the least number of units that…
- A counting semaphore starts at 7. Then 20 wait (P) operations and 15 signal (V) operations are performed on it. What is its final value?
- Which of these is NOT one of the three requirements a correct critical-section solution must meet?
- How does a microkernel operating system differ from a monolithic one?
- In the many-to-one threading model (many user-level threads mapped to one kernel thread), what happens when one thread makes a blocking…
- The main purpose of multiprogramming in an operating system is to: