Skip to content

GATE CS question library

Practise GATE CS Computer Science previous year questions free. Browse by subject, syllabus topic, year and question type, with answers and available solutions.

Subject, topic, year and type filter the full library. Match any choice within a filter, and all selected filter categories. Search, source and sort apply to this page.

20 on this page
Official PYQ2014Computer Organization and ArchitectureInstruction PipeliningNAT · 1 mark
Consider two processors P1P_1 and P2P_2 executing the same instruction set. Assume that under identical conditions, for the same input, a program running on P2P_2 takes 25%\text{25\%} less time but incurs 20%\text{20\%} more CPI (clock cycles per instruction) as compared to the program running on P1P_1. If the clock frequency of P1P_1 is …
Official PYQ2014DatabasesTuple Calculus and SQLMCQ · 1 mark
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 location ID 1700.\text{ID 1700.} You issue the following query: SQL>SELECT last-name, hire-date …
Official PYQ2014Engineering MathematicsPropositional and First Order LogicMCQ · 1 mark
Which one of the following propositional logic formulas is TRUE when exactly two of p,qp,q and rr are TRUE?
Official PYQ2014Engineering MathematicsGraphs: Connectivity, Matching, ColouringMCQ · 1 mark
An ordered n−n-tuple (d1,d2,…,dn)(d_1, d_2,\ldots,d_n) with d1≥d2≥…≥dnd_1 \geq d_2 \geq \ldots \geq d_n is called graphic if there exists a simple undirected graph with nn vertices having degrees d1,d2,…,dnd_1,d_2,\ldots,d_n respectively. Which one of the following 66-tuples is NOT graphic?
Official PYQ2014Engineering MathematicsGraphs: Connectivity, Matching, ColouringNAT · 1 mark
Consider an undirected graph GG where self-loops are not allowed. The vertex set of GG is {(i,j)∣1≤i≤12,1≤j≤12}\{(i,j) \mid1 \leq i \leq 12, 1 \leq j \leq 12\}. There is an edge between (a,b)(a,b) and (c,d)(c,d) if ∣a−c∣≤1|a-c| \leq 1 and ∣b−d∣≤1|b-d| \leq 1. The number of edges in this graph is______.
Official PYQ2014Engineering MathematicsSets, Relations and FunctionsNAT · 1 mark
Let ܵSS denote the set of all functions f:{0,1}4→{0,1}f:\{0,1\}^4 \to \{0,1\}. Denote by NN the number of functions from S to the set {0,1}\{0,1\}. The value of log⁡2log⁡2N\log_2 \log_2N is _______.
Official PYQ2014Engineering MathematicsCombinatorics: Counting, Recurrence Relations, Generating FunctionsNAT · 1 mark
A pennant is a sequence of numbers, each number being 11 or 22. An n−n-pennant is a sequence of numbers with sum equal to nn. For example, (1,1,2)(1,1,2) is a 4−4-pennant. The set of all possible 1−1-pennants is (1){(1)}, the set of all possible 2−2-pennants is (2),(1,1){(2), (1,1)} and the set of all 3−3-pennants is (2,1),(1,1,1),(1,2){(2,1), (1,1,1), (1,2)}. …
Official PYQ2014Engineering MathematicsProbability: Random Variables and DistributionsNAT · 1 mark
Four fair six-sided dice are rolled. The probability that the sum of the results being 2222 is X1296\dfrac{X}{1296}. The value of XX is _______
Official PYQ2014Engineering MathematicsCalculus: Limits, Continuity, DifferentiabilityMCQ · 1 mark
A function f(x)f(x) is continuous in the interval [0,2][0,2]. It is known that f(0)=f(2)=−1f(0) = f(2) = -1 and f(1)=1f(1) = 1. Which one of the following statements must be true?
Official PYQ2014Engineering MathematicsCalculus: Limits, Continuity, DifferentiabilityNAT · 1 mark
The function f(x)=xsin⁡xf(x) =x \sin x satisfies the following equation: f′′(x)+f(x)+tcos⁡x=0f''(x) + f(x) +t \cos x = 0The value of tt is______.
Official PYQ2014Digital LogicCombinational CircuitsMCQ · 1 mark
Consider the 4-to-14\text{-to-1} multiplexer with two select lines S1S_1 and S0S_0 given below The minimal sum-of-products form of the Boolean expression for the output FF of the multiplexer is
Official PYQ2014Computer Organization and ArchitectureMemory Hierarchy: Cache, Main Memory and Secondary StorageMCQ · 1 mark
An access sequence of cache block addresses is of length NN 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 kk. What is the miss ratio if the access sequence is passed through a cache of associativity A≥kA\geq k exercising least-recently-used …
Official PYQ2014Computer Organization and ArchitectureInstruction PipeliningNAT · 1 mark
Consider a 66-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 66-stage pipeline, the speedup achieved with respect to non-pipelined execution if 2525% of the instructions incur 22 pipeline stall cycles is ____________
Official PYQ2014AlgorithmsAsymptotic Worst Case Time and Space ComplexityMCQ · 1 mark
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
Official PYQ2014AlgorithmsAsymptotic Worst Case Time and Space ComplexityMCQ · 1 mark
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; j < size; j++) { Z = 0; for(k = i; k <= j; k++) Z = Z + E[k]; if(Z > Y) Y = Z; } return Y; } The value returned …
Official PYQ2014AlgorithmsSearching, Sorting, HashingNAT · 1 mark
The minimum number of comparisons required to find the minimum and the maximum of 100100 numbers is ________
Official PYQ2014Programming and Data StructuresArrays, Stacks and QueuesMCQ · 1 mark
Consider a hash table with 99 slots. The hash function is h(k)=kmod  9h(k)= k \mod 9. The collisions are resolved by chaining. The following 99 keys are inserted in the order: 5,28,19,15,20,33,12,17,105, 28, 19, 15, 20, 33, 12, 17, 10. The maximum, minimum, and average chain lengths in the hash table, respectively, are
Official PYQ2014Theory of ComputationTuring MachinesMCQ · 1 mark
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)?
Official PYQ2014AlgorithmsAlgorithm Design: Greedy TechniquesNAT · 1 mark
There are 55 bags labeled 11 to 55. All the coins in a given bag have the same weight. Some bags have coins of weight 1010 gm, others have coins of weight 1111 gm. I pick 1,2,4,8,161, 2, 4, 8, 16 coins respectively from bags 11 to 55 Their total weight comes out to 323323 gm. Then the product of the labels of the bags having 1111 gm coins is …
Official PYQ2014Theory of ComputationRegular Expressions and Finite AutomataMCQ · 1 mark
Which of the regular expressions given below represent the following DFA? 0∗1(1+00∗1)∗0^*1(1+00^*1)^* 0∗1∗1+11∗0∗10^*1^*1+11^*0^*1 (0+1)∗1(0+1)^*1