The Gateway to Computer Science Excellence
First time here? Checkout the FAQ!
x
0 votes
44 views
Suppose a system contains 'n' processes and system uses the round robin algorithm  for cpu scheduling then which data structure is best suited for ready queue of these process

1.stack

2.queue

3.circular queue

4.tree
closed as a duplicate of: ISRO2015-33
asked in Operating System by (219 points)
closed by | 44 views
0
I think circular queue will be the answer.
0
Please explain how will be circular queue?
0
In round robin all process are executed on the basis of given time quantum ,so processes can't be executed at once (preemption due to time quantum).assume there are 4 processes and time quantum is 2 sec and all have burst time more than 2 sec .now acc. to arrival time first process will be executed for its time quantum 2 sec ,and for remaining burst time ,you have to keep this process somewhere .because this process executed first ,second time it should be run first ,for that queue data structure is best ,first in first out .circular queue is best for this ,because we don't want overflow of queue.

Hope u understand...let me know


Quick search syntax
tags tag:apple
author user:martin
title title:apple
content content:apple
exclude -tag:apple
force match +apple
views views:100
score score:10
answers answers:2
is accepted isaccepted:true
is closed isclosed:true

35,535 questions
42,875 answers
121,904 comments
42,216 users