某系统中仅有5个并发进程竞争某类资源,且都需要该类资源3个,那么该类资源至少有(22)个,才能保证系统不会发生死锁
2023-09-01
A.9
B.10
C.11
D.15
参考答案:C
B.10
C.11
D.15
参考答案:C
假设系统为每个进程分配了2个资源,对选项C,系统还剩余1个,能保证5个进程中的一个进程运行完毕。当该进程释放其占有的资源,系统可用资源数为3个,能保证未完成的4个进程中的3个进程运行完毕。当这3个进程释放其占有的资源,系统可用资源数为9个,显见能确保最后一个进程运行完。
![]( //img1.runjiapp.com/duoteimg/tiku/images/pc/questionBank/main-list-title-icon.png)
![](https://img1.runjiapp.com/duoteimg/tiku/banner/bn_20.jpg)
![](https://img1.runjiapp.com/duoteimg/tiku/banner/bn_9.jpg)
![](https://img1.runjiapp.com/duoteimg/tiku/banner/bn_53.jpg)
![](https://img1.runjiapp.com/duoteimg/tiku/banner/bn_40.jpg)
![](https://img1.runjiapp.com/duoteimg/tiku/banner/bn_89.jpg)
![](https://img1.runjiapp.com/duoteimg/tiku/banner/bn_84.jpg)
![](https://img1.runjiapp.com/duoteimg/tiku/banner/bn_15.jpg)
![](https://img1.runjiapp.com/duoteimg/tiku/banner/bn_38.jpg)
![](https://img1.runjiapp.com/duoteimg/tiku/banner/bn_14.jpg)
热门标签