# Recent questions tagged gate2014-cse-set1

1
Consider two processors $P_1$ and $P_2$ executing the same instruction set. Assume that under identical conditions, for the same input, a program running on $P_2$ takes $\text{25%}$ less time but incurs $\text{20%}$ more CPI (clock cycles per instruction) as compared to the program ... $P_1$. If the clock frequency of $P_1$ is $\text{1GHZ}$, then the clock frequency of $P_2$ (in GHz) is ______.
2
Given the following schema: employees(emp-id, first-name, last-name, hire-date, dept-id, salary) departments(dept-id, dept-name, manager-id, location-id) You want to display the last names and hire dates of all latest hires in their respective departments in the ... because of pairwise comparison. It generates an error because of the GROUP BY clause cannot be used with table joins in a sub-query.
3
Which one of the following propositional logic formulas is TRUE when exactly two of $p,q$ and $r$ are TRUE? $(( p \leftrightarrow q) \wedge r) \vee (p \wedge q \wedge \sim r)$ $( \sim (p \leftrightarrow q) \wedge r)\vee (p \wedge q \wedge \sim r)$ $( (p \to q) \wedge r) \vee (p \wedge q \wedge \sim r)$ $(\sim (p \leftrightarrow q) \wedge r) \wedge (p \wedge q \wedge \sim r)$
4
An ordered $n-$tuple $(d_1, d_2,\ldots,d_n)$ with $d_1 \geq d_2 \geq \ldots \geq d_n$ is called graphic if there exists a simple undirected graph with $n$ vertices having degrees $d_1,d_2,\ldots,d_n$ respectively. Which one of the following $6$-tuples is NOT graphic? $(1,1,1,1,1,1)$ $(2,2,2,2,2,2)$ $(3,3,3,1,0,0)$ $(3,2,1,1,1,0)$
5
Consider an undirected graph $G$ where self-loops are not allowed. The vertex set of $G$ is $\{(i,j) \mid1 \leq i \leq 12, 1 \leq j \leq 12\}$. There is an edge between $(a,b)$ and $(c,d)$ if $|a-c| \leq 1$ and $|b-d| \leq 1$. The number of edges in this graph is______.
6
Let ܵ$S$ denote the set of all functions $f:\{0,1\}^4 \to \{0,1\}$. Denote by $N$ the number of functions from S to the set $\{0,1\}$. The value of $\log_2 \log_2N$ is _______.
7
A pennant is a sequence of numbers, each number being $1$ or $2$. An $n-$pennant is a sequence of numbers with sum equal to $n$. For example, $(1,1,2)$ is a $4-$pennant. The set of all possible $1-$pennants is ${(1)}$, the set of all possible $2-$ ... $(1,2)$ is not the same as the pennant $(2,1)$. The number of $10-$pennants is________
8
Four fair six-sided dice are rolled. The probability that the sum of the results being $22$ is $\dfrac{X}{1296}$. The value of $X$ is _______
9
A function $f(x)$ is continuous in the interval $[0,2]$. It is known that $f(0) = f(2) = -1$ and $f(1) = 1$. Which one of the following statements must be true? There exists a $y$ in the interval $(0,1)$ such that $f(y) = f(y+1)$ For every $y$ ... maximum value of the function in the interval $(0,2)$ is $1$ There exists a $y$ in the interval $(0,1)$ such that $f(y)$ = $-f(2-y)$
10
The function $f(x) =x \sin x$ satisfies the following equation: $f''(x) + f(x) +t \cos x = 0$The value of $t$ is______.
11
Consider the $4\text{-to-1}$ multiplexer with two select lines $S_1$ and $S_0$ given below The minimal sum-of-products form of the Boolean expression for the output $F$ of the multiplexer is $\bar{P}Q + Q\bar{R} + P\bar{Q}R$ $\bar{P}Q + \bar{P}Q\bar{R} + PQ\bar{R} + P\bar{Q}R$ $\bar{P}QR + \bar{P}Q\bar{R} + Q\bar{R} + P\bar{Q}R$ $PQ\bar{R}$
12
An access sequence of cache block addresses is of length $N$ and contains n unique block addresses. The number of unique block addresses between two consecutive accesses to the same block address is bounded above by $k$. What is the miss ratio if the access sequence is passed through a cache of ... $\left(\dfrac{1}{N}\right)$ $\left(\dfrac{1}{A}\right)$ $\left(\dfrac{k}{n}\right)$
13
Consider a $6$-stage instruction pipeline, where all stages are perfectly balanced. Assume that there is no cycle-time overhead of pipelining. When an application is executing on this $6$-stage pipeline, the speedup achieved with respect to non-pipelined execution if $25$% of the instructions incur $2$ pipeline stall cycles is ____________
14
Consider the following pseudo code. What is the total number of multiplications to be performed? D = 2 for i = 1 to n do for j = i to n do for k = j + 1 to n do D = D * 3 Half of the product of the $3$ consecutive integers. One-third of the product of the $3$ consecutive integers. One-sixth of the product of the $3$ consecutive integers. None of the above.
15
Consider the following C function in which size is the number of elements in the array E: int MyX(int *E, unsigned int size) { int Y = 0; int Z; int i, j, k; for(i = 0; i< size; i++) Y = Y + E[i]; for(i=0; i < size; i++) for(j = i; ... E. maximum element in any sub-array of array E. sum of the maximum elements in all possible sub-arrays of array E. the sum of all the elements in the array E.
16
Consider a hash table with $9$ slots. The hash function is $h(k)= k \mod 9$. The collisions are resolved by chaining. The following $9$ keys are inserted in the order: $5, 28, 19, 15, 20, 33, 12, 17, 10$. The maximum, minimum, and average chain lengths in the hash table, respectively, are $3, 0,$ and $1$ $3, 3,$ and $3$ $4, 0,$ and $1$ $3, 0,$ and $2$
17
The minimum number of comparisons required to find the minimum and the maximum of $100$ numbers is ________
18
Suppose a polynomial time algorithm is discovered that correctly computes the largest clique in a given graph. In this scenario, which one of the following represents the correct Venn diagram of the complexity classes P, NP and NP Complete (NPC)?
19
There are $5$ bags labeled $1$ to $5$. All the coins in a given bag have the same weight. Some bags have coins of weight $10$ gm, others have coins of weight $11$ gm. I pick $1, 2, 4, 8, 16$ coins respectively from bags $1$ to $5$ Their total weight comes out to $323$ gm. Then the product of the labels of the bags having $11$ gm coins is ___.
20
Which of the regular expressions given below represent the following DFA? $0^*1(1+00^*1)^*$ $0^*1^*1+11^*0^*1$ $(0+1)^*1$ I and II only I and III only II and III only I, II and III
21
Let $L$ be a language and $\bar{L}$ be its complement. Which one of the following is NOT a viable possibility? Neither $L$ nor $\bar{L}$ is recursively enumerable $(r.e.)$. One of $L$ and $\bar{L}$ is r.e. but not recursive; the other is not r.e. Both $L$ and $\bar{L}$ are r.e. but not recursive. Both $L$ and $\bar{L}$ are recursive.
22
A canonical set of items is given below $S \to L .> R$ $Q \to R.$ On input symbol $<$ the set has a shift-reduce conflict and a reduce-reduce conflict. a shift-reduce conflict but not a reduce-reduce conflict. a reduce-reduce conflict but not a shift-reduce conflict. neither a shift-reduce nor a reduce-reduce conflict.
23
Assume that there are $3$ page frames which are initially empty. If the page reference string is $\text{1, 2, 3, 4, 2, 1, 5, 3, 2, 4, 6}$ the number of page faults using the optimal replacement policy is__________.
24
Consider the following set of processes that need to be scheduled on a single CPU. All the times are given in milliseconds. ... Using the shortest remaining time first scheduling algorithm, the average process turnaround time (in msec) is ____________________.
25
An operating system uses the Banker's algorithm for deadlock avoidance when managing the allocation of three resource types $X, Y,$ and $Z$ to three processes $P0, P1,$ and $P2.$ The table given below presents the current system state. Here, the Allocation matrix ... REQ1 can be permitted. Only REQ2 can be permitted. Both REQ1 and REQ2 can be permitted. Neither REQ1 nor REQ2 can be permitted.
26
Given the following two statements: S1: Every table with two single-valued attributes is in 1NF, 2NF, 3NF and BCNF. S2: $AB \to C$, $D \to E$, $E \to C$ is a minimal cover for the set of functional dependencies $AB \to C$, $D \to E$, $AB \to E$, $E \to C$. ... one of the following is CORRECT? S1 is TRUE and S2 is FALSE. Both S1 and S2 are TRUE. S1 is FALSE and S2 is TRUE. Both S1 and S2 are FALSE.
27
Consider the following four schedules due to three transactions (indicated by the subscript) using read and write on a data item x, denoted by $r(x)$ and $w(x)$ respectively. Which one of them is conflict serializable? $r_1(x)$; $r_2(x)$; $w_1(x)$; $r_3(x)$; $w_2(x)$; $r_2(x)$; $r_1(x)$; $w_2(x)$ ... $r_2(x)$; $r_1(x)$; $w_2(x)$; $w_1(x)$; $r_2(x)$; $w_2(x)$; $r_3(x)$; $r_1(x)$; $w_1(x)$;
Consider a selective repeat sliding window protocol that uses a frame size of $1$ $\text{KB}$ to send data on a $1.5$ $\text{Mbps}$ link with a one-way latency of $50$ $\text{msec}$. To achieve a link utilization of $60\%$, the minimum number of bits required to represent the sequence number field is ________.
Let the size of congestion window of a TCP connection be $32$ KB when a timeout occurs. The round trip time of the connection is $100$ msec and the maximum segment size used is $2$ KB. The time taken (in msec) by the TCP connection to get back to $32$ KB congestion window is _________.
Consider a token ring network with a length of 2 km having 10 stations including a monitoring station. The propagation speed of the signal is $2 \times10^8m/s$ and the token transmission time is ignored. If each station is allowed to hold the token for $2 µsec$, the minimum time for which the monitoring station should wait (in $µsec$) before assuming that the token is lost is _______.