看板 Grad-ProbAsk 關於我們 聯絡資訊
Consider the following preemptive priority-scheduling algorithn based on dynamically changing priorities. Larger priority numbers imply higher priority. When a process is waiting for the CPU(in the ready queue,but not running),its priority changes at a rate A;when it is running,its priority changes at a rate B. All processes are given a priority of 0 when they enter the ready queue. The parameters A and B can be to give many different scheduling Algorithms. (a) What is the algorithm that result from B > A > 0. (b) What is the algorithm that result from A < B < 0. 我知道答案(a)LIFO (b)FCFS 但我不明白為什麼是這樣 照題目給的 B的 優先權值應該會恆大於A 所以兩個都解釋成FCFS也行的通吧 難道是我誤會了什麼嗎? 有請大大解答 謝謝 -- ※ 發信站: 批踢踢實業坊(ptt.cc) ◆ From: 114.27.133.68
eddie780217:這今年中山資工的第一題耶.... 03/10 18:16
xygod:你答案好像寫反了。 03/10 18:47
compulsory:這題好像很夯= = 清大也考 03/10 18:50
ji3g4m0:中山小題好像是反過來 03/10 19:01
aoqq12:原文書 是那樣寫 不過我也是都覺得FCFS 03/10 19:26
aoqq12:-3<-2 奇怪哩 他們怎麼會覺得 -2的速率扣的快 03/10 19:26
aoqq12:所以中山我都寫FCFS...= = 03/10 19:26
aoqq12:不過請還是照著原文書走吧.. 03/10 19:27
marvintim77:這題很夯阿 中山今年考第二次了 03/10 23:15