CS and IT GATE 2017 Set-1 Questions with Answer

Ques 53 Mathematics


Let X be a Gaussian random variable with mean 0 and variance σ2. Let Y = max(X,0) where max(a,b) is the maximum of a and b. The median of Y is _____.


0 is the correct answer.


Ques 54 Operating System


Consider the following CPU processes with arrival times (in milliseconds) and length of CPU bursts (in milliseconds) as given below:

Process Arrival Time Brust Time
P1 0 7
P2 3 3
P3 5 5
P4 6 2


If the pre-emptive shortest remaining time first scheduling algorithm is used to schedule the processes, then the average waiting time across all processes is _______ milliseconds.


a is the correct answer.


Ques 55 Operating System


Recall that Belady’s anomaly is that the pages-fault rate may increase as the number of allocated frames increases. Now consider the following statements:

S1: Random page replacement algorithm (where a page chosen at random is replaced) suffers from Belady’s anomaly.
S2: LRU page replacement algorithm suffer from Belady’s anomaly .


Which of the following is CORRECT?

A

S1 is true, S2 is true

B

S1 is true, S2 is false

C

S1 is false , S2 is true

D

S1 is false, S2 is false



Ques 56 Operating System


A multithreaded program P executes with x number of threads and uses y number of locks for ensuring mutual exclusion while operating on shared memory locations. All locks in the program are non-reentrant, i.e., if a thread holds a lock l, then it cannot re-acquire lock l without releasing it. If a thread is unable to acquire a lock, it blocks until the lock becomes available. The minimum value of x and the minimum value of y together for which execution of P can result in a deadlock are:

A

x = 1, y = 2

B

x = 2, y = 1

C

x = 2, y = 2

D

x = 1, y = 1



Ques 57 Operating System


Threads of a process share

A

global variables but not heap

B

heap but not global variables.

C

neither global variables nor heap.

D

both heap and global variables.



Unique Visitor Count

Total Unique Visitors

Loading......