GATE 2012 CS (CS1) – Previous Year Questions with Solutions
All 65 questions of GATE 2012 CS (CS1) with answers and explanations. Read each question, then practise it by topic or as a full paper.
Practise this paper in The GATE Grind →
- Question 1 – A firm’s cost is 5q2 for production q and its selling price is 50 per unit. How many units maximize profit?
- Question 2 – Despite several the mission succeeded in its attempt to resolve the conflict.
- Question 3 – Choose the closest meaning of “mitigate”.
- Question 4 – Choose the grammatically INCORRECT sentence.
- Question 5 – Suresh’s dog is the one was hurt in the stampede.
- Question 6 – Wanted Temporary, Part-time persons for the post of Field Interviewer to conduct personal interviews to collect and collate economic data.…
- Question 7 – An entrance arch for a political party’s annual convention has profile y=2x-0.1x2, where y is height in metres. What is its maximum height?
- Question 8 – Supplier X provides 60% and Y 40% of a plant’s shock absorbers. A quality test identifies reliable units: 96% of X’s and 72% of Y’s pass. A randomly…
- Question 9 – Which assertions are correct? P: Adding seven to every list entry adds seven to the mean. Q: It adds seven to standard deviation. R: Doubling every…
- Question 10 – Continue the sequence AD, CG, FK, JP.
- Question 11 – I₁: If it rains, the cricket match will not be played; the match was played; infer no rain. I₂: If it rains, the match will not be played; it did not…
- Question 12 – Which statement is true?
- Question 13 – Find the output of the printed C fragment. Several case labels below retain the source’s semicolons.
- Question 14 – Assuming P≠NP, which is true?
- Question 15 – Find the worst-case search time in a balanced BST with n2n elements.
- Question 16 – A truth table gives f(0,0)=0, f(0,1)=0, f(1,0)=1, f(1,1)=1. Which Boolean function is it?
- Question 17 – The decimal number 0.5 in IEEE single precision has
- Question 18 – A process executes fork(); fork(); fork();. How many child processes are created?
- Question 19 – For f(x)=sin x on [π/4,7π/4], find the local minima and their locations.
- Question 20 – The application-layer protocol data unit in the Internet stack is called a
- Question 21 – A is 2×2 with a₁₁=a₁₂=a₂₁=1 and a₂₂=−1. Find the eigenvalues of A¹⁹.
- Question 22 – Over alphabet a, with ε the empty string, find the complement of the language accepted by the shown NFA.
- Question 23 – Translate “Some real numbers are rational” into logic.
- Question 24 – For basic ER and relational models, which is incorrect?
- Question 25 – Which SQL assertions are true? P: HAVING can occur without GROUP BY. Q: HAVING requires GROUP BY. R: Every GROUP BY attribute must appear in SELECT.…
- Question 26 – Which recurrence gives optimal Towers of Hanoi time for n disks?
- Question 27 – A connected simple planar graph has ten vertices and fifteen edges. How many bounded faces does any plane embedding have?
- Question 28 – W(n) and A(n) are worst-case and average running times on inputs of size n. Which always holds?
- Question 29 – How much ROM implements a four-bit multiplier?
- Question 30 – Register renaming in pipelined processors is done
- Question 31 – X equals −1 or +1 with probability 0.5 each. Find F(−1),F(+1) for its cumulative distribution.
- Question 32 – Which transport-layer protocol supports electronic mail?
- Question 33 – In classful IPv4, how many Class C networks are possible?
- Question 34 – Which problems are decidable? 1: Does an arbitrary program ever output anything? 2: Given a CFL L, is L context-free? 3: Given regular L, is L…
- Question 35 – L=ab,aa,baa. Which strings belong to L*? 1: abaabaaabaa; 2: aaaabaaaa; 3: baaaaabaaaab; 4: baaaaabaa.
- Question 36 – Which graph A,B,C,D is isomorphic to the given graph?
- Question 37 – P=Q=0 initially. T₁ executes read(P); read(Q); if P==0 then Q:=Q+1; write(Q). T₂ executes read(Q); read(P); if Q==0 then P:=P+1; write(P). Any…
- Question 38 – Apply bisection to f(x)=x4-x3-x2-4 on [1,9]. After how many iterations is an exact zero found?
- Question 39 – A graph G has edge weights greater than one. G′ squares every edge weight. T,T′ are minimum spanning trees with weights t,t′. Which is true?
- Question 40 – Minimize the shown four-variable Karnaugh map. X marks don’t-care cells; blank cells are zeros.
- Question 41 – Processes P₁,P₂,P₃ have (arrival,CPU time) (0,5),(1,7),(3,4). Find completion orders for FCFS and round robin with quantum two.
- Question 42 – Fetch And Add(L,i) atomically returns old L and increments L by i. Shared unsigned L initially zero means unlocked; nonzero means locked. Assess this…
- Question 43 – Roll a fair six-sided die once. If the first value is 1,2 or 3, roll again. What is the probability the total rolled value is at least six?
- Question 44 – An ISP holds CIDR block 245.248.128.0/20. Half goes to A, one quarter to B, and the rest is retained. Which A,B allocation is valid?
- Question 45 – A circular queue stores at most n−1 items in an n-element array. REAR and FRONT index insertion/deletion positions and both start zero. Identify full…
- Question 46 – In a lexically scoped block-structured language, main contains sibling procedures A1 and A2; A2 contains A21. A1 calls A2; A2 calls A21; A21 calls A1;…
- Question 47 – How many surjections exist from an n-element set (n≥2) to a two-element set?
- Question 48 – A complete undirected graph has six labelled vertices. How many distinct cycles of length four does it contain?
- Question 49 – Merge sort lexicographically sorts n strings, each of length n. What is the worst-case running time?
- Question 50 – For the shown directed weighted graph, several S-to-T shortest paths exist. Dijkstra updates a vertex’s predecessor only on finding a strictly shorter…
- Question 51 – A 300 GB disk uses file descriptors with eight direct block addresses, one indirect and one doubly indirect. Block size is 128 bytes and each address…
- Question 52 – With three initially empty frames, reference string is 1,2,3,2,4,1,3,2,4,1. Let LRU,FIFO,OPTIMAL be fault counts. Which relation holds?
- Question 53 – R₁(A,B) and R₂(C,D) have instances r₁,r₂. B references C as a foreign key and referential integrity holds. Which always holds?
- Question 54 – S sends a 10⁶-bit file through routers R₁,R₂ over three 1 Mb/s links, each 100 km long with propagation speed 10⁸ m/s. The file is split into 1000…
- Question 55 – TCP AIMD starts slow start with window 2 MSS and initial threshold 8 MSS. A timeout occurs during transmission five. Find congestion window at the end…
- Question 56 – Over 0,1, every three-symbol substring must contain at most two zeros; all words shorter than three are included. The partial DFA is shown. Which…
- Question 57 – Height counts edges on the longest downward path. Fill B1 and B2.
- Question 58 – What are the three output lines?
- Question 59 – For the same complete code below, replace Line 1 with auto int a=1 and Line 2 with register int a=2. What are the three output lines?
- Question 60 – A(Id,Name,Age)=(12,Arun,60),(15,Shreya,24),(99,Rohit,11); B(Id,Name,Age)=(15,Shreya,24),(25,Hari,40),(98,Rohit,20),(99,Rohit,11);…
- Question 61 – A(Id,Name,Age)=(12,Arun,60),(15,Shreya,24),(99,Rohit,11); B(Id,Name,Age)=(15,Shreya,24),(25,Hari,40),(98,Rohit,20),(99,Rohit,11);…
- Question 62 – S→aAbB bAaB ε; A→S; B→S. The partial predictive table has S row (E1,E2,S→ε), A row (A→S,A→S,error), B row (B→S,B→S,E3), for lookaheads a,b,end-marker…
- Question 63 – S→aAbB bAaB ε; A→S; B→S. The partial predictive table has S row (E1,E2,S→ε), A row (A→S,A→S,error), B row (B→S,B→S,E3), for lookaheads a,b,end-marker…
- Question 64 – A computer has a 256 KB, four-way set-associative, write-back data cache, 32-byte blocks and 32-bit addresses. Every tag-directory entry includes the…
- Question 65 – A computer has a 256 KB, four-way set-associative, write-back data cache, 32-byte blocks and 32-bit addresses. Every tag-directory entry includes the…