Use app×
Join Bloom Tuition
One on One Online Tuition
JEE MAIN 2025 Foundation Course
NEET 2025 Foundation Course
CLASS 12 FOUNDATION COURSE
CLASS 10 FOUNDATION COURSE
CLASS 9 FOUNDATION COURSE
CLASS 8 FOUNDATION COURSE
0 votes
549 views
in Computer by (106k points)
closed by
What is the minimum number of resources required to ensure that deadlock will never occur, if there are currently three processes P1, P2, and P3 running in a system whose maximum demand for the resources of the same type are 3, 4, and 5 respectively?
1. 3
2. 7
3. 9
4. 10

1 Answer

0 votes
by (106k points)
selected by
 
Best answer
Correct Answer - Option 4 : 10

The correct answer is option 4:

Data:

Maximum resource requirement of Process P1 = 3

Maximum resource requirement of Process P2 = 4

Maximum resource requirement of Process P3 = 5

Concept:

Deadlock can occur If any process gets available resource < demanded resource

Max resource for process P1 to be in deadlock = needed - 1 = 3 - 1 = 2

Max resource for process P2 to be in deadlock = needed - 1 = 4 - 1 = 3

Max resource for process P3 to be in deadlock = needed - 1 = 5 - 1 = 4

If one resource is added, any of the n processes can take it a finish its execution leaving behind the allocated resource, and hence the system will be deadlock-free.

Calculation:

The minimum value of m that ensures that deadlock will never occur = (2 + 3 + 4) + 1 = 10

Welcome to Sarthaks eConnect: A unique platform where students can interact with teachers/experts/students to get solutions to their queries. Students (upto class 10+2) preparing for All Government Exams, CBSE Board Exam, ICSE Board Exam, State Board Exam, JEE (Mains+Advance) and NEET can ask questions from any subject and get quick answers by subject teachers/ experts/mentors/students.

Categories

...