A directory of Objective Type Questions covering all the Computer Science subjects. Here you can access and discuss Multiple choice questions and answers for various compitative exams and interviews.

91. If the quantum time of round robin algorithm is very large, then it is equivalent to:
a. First in first out
b. Shortest Job Next
c. Lottery scheduling
d. None of the above
View Answer Report Discuss Too Difficult! Search Google
Answer: (a).First in first out

92. A scheduling algorithm assigns priority proportional to the waiting time of a process. Every process starts with priority zero (the lowest priority). The scheduler re-evaluates the process priorities every T time units and decides the next process to schedule. Which one of the following is TRUE if the processes have no I/O operations and all arrive at time zero?
a. This algorithm is equivalent to the first-come-first-serve algorithm
b. This algorithm is equivalent to the round-robin algorithm
c. This algorithm is equivalent to the shortest-job-first algorithm
d. This algorithm is equivalent to the shortest-remaining-time-first algorithm
View Answer Report Discuss Too Difficult! Search Google
Answer: (b).This algorithm is equivalent to the round-robin algorithm

93. Consider the 3 processes, P1, P2 and P3 shown in the table.
Process Arrival time Time Units Required
P1 0 5
P2 1 7
P3 3 4
The completion order of the 3 processes under the policies FCFS and RR2 (round robin scheduling with CPU quantum of 2 time units) are
a. FCFS: P1, P2, P3 RR2: P1, P2, P3
b. FCFS: P1, P3, P2 RR2: P1, P3, P2
c. FCFS: P1, P2, P3 RR2: P1, P3, P2
d. FCFS: P1, P3, P2 RR2: P1, P2, P3
View Answer Report Discuss Too Difficult! Search Google
Answer: (c).FCFS: P1, P2, P3 RR2: P1, P3, P2

94. Consider the following table of arrival time and burst time for three processes P0, P1 and P2.

Process Arrival time Burst Time
P0 : 0 ms 9 ms
P1 : 1 ms 4 ms
P2 : 2 ms 9 ms

The pre-emptive shortest job first scheduling algorithm is used. Scheduling is carried out only at arrival or completion of processes. What is the average waiting time for the three processes?
a. 5.0 ms
b. 4.33 ms
c. 6.33
d. 7.33
View Answer Report Discuss Too Difficult! Search Google
Answer: (a).5.0 ms

95. Which of the following statements are true?

I. Shortest remaining time first scheduling may cause starvation
II. Preemptive scheduling may cause starvation
III. Round robin is better than FCFS in terms of response time
a. I only
b. I and III only
c. II and III only
d. I, II and III
View Answer Report Discuss Too Difficult! Search Google
Answer: (d).I, II and III

96. Group 1 contains some CPU scheduling algorithms and Group 2 contains some applications. Match entries in Group 1 to entries in Group 2.

Group I Group II
(P) Gang Scheduling (1) Guaranteed Scheduling
(Q) Rate Monotonic Scheduling (2) Real-time Scheduling
(R) Fair Share Scheduling (3) Thread Scheduling
a. P – 3 Q – 2 R – 1
b. P – 1 Q – 2 R – 3
c. P – 2 Q – 3 R – 1
d. P – 1 Q – 3 R – 2
View Answer Report Discuss Too Difficult! Search Google
Answer: (a).P – 3 Q – 2 R – 1

97. An operating system uses Shortest Remaining Time first (SRT) process scheduling algorithm. Consider the arrival times and execution times for the following processes:

Process Execution time Arrival time
P1 : 20 0
P2 : 25 15
P3 : 10 30
P4 : 15 45

What is the total waiting time for process P2?
a. 5
b. 15
c. 40
d. 55
View Answer Report Discuss Too Difficult! Search Google
Answer: (b).15

98. Three processes A, B and C each execute a loop of 100 iterations. In each iteration of the loop, a process performs a single computation that requires tc CPU milliseconds and then initiates a single I/O operation that lasts for tio milliseconds. It is assumed that the computer where the processes execute has sufficient number of I/O devices and the OS of the computer assigns different I/O devices to each process. Also, the scheduling overhead of the OS is negligible. The processes have the following characteristics:

Process id tc tio
A : 100 ms 500 ms
B : 350 ms 500 ms
C : 200 ms 500 ms

The processes A, B, and C are started at times 0, 5 and 10 milliseconds respectively, in a pure time sharing system (round robin scheduling) that uses a time slice of 50 milliseconds. The time in milliseconds at which process C would complete its first I/O operation is ___________.
a. 500
b. 1000
c. 2000
d. 10000
View Answer Report Discuss Too Difficult! Search Google
Answer: (b).1000

99. An operating system uses shortest remaining time first scheduling algorithm for pre-emptive scheduling of processes. Consider the following set of processes with their arrival times and CPU burst times (in milliseconds):

Process : Arrival Time Burst Time
P1 : 0 12
P2 : 2 4
P3 : 3 6
P4 : 8 5

The average waiting time (in milliseconds) of the processes is _________.
a. 4.5
b. 5.0
c. 5.5
d. 6.5
View Answer Report Discuss Too Difficult! Search Google
Answer: (c).5.5

100. Consider the following set of processes, with the arrival times and the CPU-burst times given in milliseconds

Process: Arrival Time Burst Time
P1 : 0 5
P2 : 1 3
P3 : 2 3
P4 : 4 1

What is the average turnaround time for these processes with the preemptive shortest remaining processing time first (SRPT) algorithm ?
a. 5.50
b. 5.75
c. 6.00
d. 6.25
View Answer Report Discuss Too Difficult! Search Google
Answer: (a).5.50

Page 10 of 16