GATE 2017 (Session 1) Computer Science and Information Technology (CS) Questions with Solutions

GATE 2017 (Session 1)

64 questions

MCQ 44 · NAT 201-mark 30 · 2-mark 34

Questions 31–35 of 64

Q31Boolean Algebra1 markNAT
Consider the Karnaugh map given below, where x represents "don't care" and blank represents 0.
ba dc 00 01 11 10 00 01 11 10 x x 1 x 1 1 x x
Assume for all inputs (a, b, c, d) the respective complements (aˉ,bˉ,cˉ,dˉ)(\bar{a},\bar{b},\bar{c},\bar{d}) are also available. The above logic is implemented 2-input NOR gates only. The minimum number of gates required is ____________.

Q32Finite Automata1 markNAT
Consider the language L given by the regular expression (a+b )* b (a+b ) over the alphabet {a, b}. The smallest number of states needed in a deterministic finite-state automation (DFA) accepting L is ___________.

Q33SQL1 markNAT
Consider a database that has the relation schema EMP (EmpId, EmpName, and DeptName). An instance of the schema EMP and a SQL query on it are given below.
EMP
EmpIdEmpNameDeptName
1XYAAA
2XYBAA
3XYCAA
4XYDAA
5XYEAB
6XYFAB
7XYGAB
8XYHAC
9XYIAC
10XYJAC
11XYKAD
12XYLAD
13XYMAE
SELECT AVG(EC.Num)
FROM EC
WHERE (DeptName, Num) IN
      (SELECT DeptName, COUNT(EmpId) AS
                        EC(DeptName, Num)
       FROM EMP
       GROUP BY DeptName)
The output of executing the SQL query is _____.

Q34CPU Scheduling1 markNAT
Consider the following CPU processes with arrival times (in milliseconds) and length of CPU burst (in milliseconds) as given below:
Process Arrival time Burst 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.

Q35Cache Memory1 markNAT
Consider a two-level cache hierarchy with L1 and L2 caches. An application incurs 1.4 memory accesses per instruction on average. For this application, the miss rate of L1 cache 0.1, the L2 cache experiences, on average, 7 misses per 1000 instructions. The miss rate of L2 expressed correct to two decimal places is ___________.