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 NetworksFragmentation and IP Addressing, IPv4, CIDRMCQ · 1 mark
Host A (on TCP/IP v4 network A) sends an IP datagram D to host B (also on TCP/IP v4 network B). Assume that no error occurred during the transmission of D. When D reaches B, which of the following IP header field(s) may be different from that of the original datagram D? TTL Checksum Fragment Offset
Official PYQ2014Computer NetworksData Link Layer: Framing, Error Detection, MAC, Ethernet BridgingMCQ · 1 mark
A bit-stuffing based framing protocol uses an 8-bit\text{8-bit} delimiter pattern of 01111110.01111110. If the output bit-string after stuffing is 01111100101,01111100101, then the input bit-string is:
Official PYQ2014Computer NetworksConcept of Layering: OSI and TCP/IP Protocol StacksMCQ · 1 mark
In the following pairs of OSI protocol layer/sub-layer and its functionality, the INCORRECT pair is
Official PYQ2014DatabasesIntegrity ConstraintsMCQ · 1 mark
A prime attribute of a relation scheme RR is an attribute that appears
Official PYQ2014DatabasesRelational Model: Relational AlgebraMCQ · 1 mark
What is the optimized version of the relation algebra expression πA1(πA2(σF1(σF2(r))))\pi_{A1}(\pi_{A2}(\sigma_{F1}(\sigma_{F2}(r)))), where A1,A2A1, A2 are sets of attributes in rr with A1⊂A2A1 \subset A2 and F1,F2F1,F2 are Boolean expressions based on the attributes in rr?
Official PYQ2014Operating SystemMemory Management and Virtual MemoryNAT · 1 mark
A system uses 33 page frames for storing process pages in main memory. It uses the Least Recently Used (LRU) page replacement policy. Assume that all the page frames are initially empty. What is the total number of page faults that will occur while processing the page reference string given below? 4, 7, 6, 1, 7, 6, 1, 2, 7, 2\text{4, 7, 6, 1, 7, 6, 1, 2, 7, 2}
Official PYQ2014Software Engineering (Historical)MCQ · 1 mark
In the context of modular software design, which one of the following combinations is desirable?
Official PYQ2014Compiler DesignIntermediate Code GenerationMCQ · 1 mark
One of the purposes of using intermediate code in compilers is to
Official PYQ2014Compiler DesignRuntime EnvironmentsMCQ · 1 mark
Which of the following statements are CORRECT? Static allocation of all data areas by a compiler makes it impossible to implement recursion. Automatic garbage collection is essential to implement recursion. Dynamic allocation of activation records is essential to implement recursion. Both heap and stack are essential to implement recursion.
Official PYQ2014Theory of ComputationRegular and Context-free LanguagesMCQ · 1 mark
Let Σ\Sigma be a finite non-empty alphabet and let 2Σ∗2^{\Sigma^*} be the power set of Σ∗\Sigma^*. Which one of the following is TRUE?
Official PYQ2014Theory of ComputationRegular Expressions and Finite AutomataNAT · 1 mark
The length of the shortest string NOT in the language (over Σ={a,b})\Sigma = \{a, b\}) of the following regular expression is _______. a∗b∗(ba)∗a∗a^*b^*(ba)^*a^*
Official PYQ2014AlgorithmsSearching, Sorting, HashingMCQ · 1 mark
You have an array of nn elements. Suppose you implement quicksort by always choosing the central element of the array as the pivot. Then the tightest upper bound for the worst case performance is
Official PYQ2014AlgorithmsGraph Traversals (BFS, DFS)NAT · 1 mark
Suppose depth first search is executed on the graph below starting at some unknown vertex. Assume that a recursive call to visit a vertex is made only after first checking that the vertex has not been visited earlier. Then the maximum possible recursion depth (including the initial call) is _________.
Official PYQ2014Programming and Data StructuresTreesMCQ · 1 mark
Consider the following rooted tree with the vertex labeled PP as the root: The order in which the nodes are visited during an in-order traversal of the tree is
Official PYQ2014Compiler DesignLocal OptimizationNAT · 1 mark
The minimum number of arithmetic operations required to evaluate the polynomial P(X)=X5+4X3+6X+5P(X) = X^5+4X^3+6X+5 for a given value of XX, using only one temporary variable is ______.
Official PYQ2014AlgorithmsAsymptotic Worst Case Time and Space ComplexityMCQ · 1 mark
Let AA be the square matrix of size n×nn \times n. Consider the following pseudocode. What is the expected output? C=100; for i=1 to n do for j=1 to n do { Temp = A[i][j]+C; A[i][j] = A[j][i]; A[j][i] = Temp -C; } for i=1 to n do for j=1 to n do output (A[i][j]);
Official PYQ2014Computer Organization and ArchitectureInstruction PipeliningMCQ · 1 mark
Consider the following processors (ns stands for nanoseconds). Assume that the pipeline registers have zero latency. P1:\text{P1:} Four-stage pipeline with stage latencies 1 ns, 2 ns, 2 ns, 1 ns\text{1 ns, 2 ns, 2 ns, 1 ns}. P2:\text{P2:} Four-stage pipeline with stage latencies 1 ns, 1.5 ns, 1.5 ns, 1.5 ns\text{1 ns, 1.5 ns, 1.5 ns, 1.5 ns}. P3:\text{P3:} Five-stage pipeline with stage latencies …
Official PYQ2014Digital LogicCombinational CircuitsMCQ · 1 mark
Consider the following combinational function block involving four Boolean variables x, y, a, bx,\:y,\:a,\:b where x, a, bx,\:a,\:b are inputs and yy is the output. f(x, a, b, y) { if(x is 1) y = a; else y = b; } Which one of the following digital logic blocks is the most suitable for implementing this function?
Official PYQ2014Digital LogicMinimization (K-Maps etc.)MCQ · 1 mark
Consider the following minterm expression for FF: F(P,Q,R,S)=∑0,2,5,7,8,10,13,15F(P,Q,R,S) = \sum 0,2,5,7,8,10,13,15 The minterms 22, 77, 88 and 1313 are 'do not care' terms. The minimal sum-of-products form for FF is
Official PYQ2014Engineering MathematicsMaxima and Minima, Mean Value Theorem, IntegrationNAT · 1 mark
If ∫02π∣x sin⁡x∣dx=kπ\int \limits_0^{2 \pi} |x \: \sin x| dx=k\pi, then the value of kk is equal to ______.