The GATE 2026 Computer Science and Information Technology (CS-2) master question paper is available here with detailed solutions. GATE 2026 CS-2 was conducted by IIT Guwahati on February 8, 2026, from 2:30 PM to 5:30 PM, as a 65-question computer-based test for 100 marks.
| GATE 2026 CS-2 Question Paper with Solutions | Download PDF | Check Solutions |
GATE 2026 CS-2 Master Paper Questions with Solutions
Expedite, Hasten, Hurry,
Fill the blank by choosing a word with a meaning similar to that of the words given above.
A black square \(PQRS\) has been cut into two parts. One part of it is shown in Panel I. Which one of the shapes in Panel II is the other part?
A day can only be cloudy or sunny. The probability of a day being cloudy is \(0.5\), independent of the condition on other days. What is the probability that in any given four days, there will be three cloudy days and one sunny day?
The values of Stock A and Stock B on a particular day are Rs. 50 and Rs. 80, respectively. An investor invests Rs. 100 in Stock A and Rs. 80 in Stock B. He sells all the stocks the next day when Stock A is Rs. 55 and Stock B is Rs. 70. The profit made is Rs. .
‘When it is raining, peacocks dance.’ Based only on this sentence, which one of the following options is necessarily true?
Water : \(P\) :: Food : \(Q\). Choose the \(P,Q\) combination that forms a meaningful analogy.
Two tiles are missing in Panel I. Which option in Panel II is the appropriate choice for the missing tiles?
Figures (i) and (ii) represent intercity highway systems. Black dots are cities and line segments are highways. A salesperson must start at a city, visit every remaining city exactly once, and return to the starting city. Which option is true?
Panel I is a four-row, four-column grid. The numbers on top and on the left give the number of cells to be shaded in each column and row, respectively. Which option in Panel II is shaded correctly?
An unbiased six-faced dice with faces \(1,2,3,4,5,6\) is rolled twice in succession. What is the probability that the sum of the two recorded numbers is prime?
For two different persons \(x,y\), \(M(x,y)\) denotes that \(x\) knows \(y\). Which expression represents: ‘There is a person who does not know anyone else, but that person is known by everyone else’?
Set \(T\) lists I: Inorder, II: Preorder, III: Postorder binary-tree traversals. Set \(S\) lists L: left subtree, node, right subtree; M: node, left subtree, right subtree; N: left subtree, right subtree, node. Which is the correct match?
Which statement is equivalent to the assertion that Turing machine \(M\) decides the language \(L\subseteq\{0,1\}^*\)?
A real-valued random variable \(X\) has density \(f(x)=\frac{1}{3\sqrt{2\pi}}\exp(-x^2/18)\), for \(x\in(-\infty,+\infty)\). Which statement is correct?
In DBMS, set \(T\) contains I: Logical schema, II: Physical schema, III: External schema. Set \(S\) contains L: Views, M: File organization and indexes, N: Relations. Which is the correct match?
Which option is not a property of Boolean algebra? Here \(+\) is OR, \(\cdot\) is AND, and prime is NOT.
In a C runtime environment, which one of the following is stored in the heap?
Consider CPU interrupts. S1: In a non-vectored interrupt mechanism, it usually takes more time to start the ISR than in a vectored mechanism. S2: In a daisy-chain mechanism, the CPU polls all input devices individually to determine the interrupt source. Which option is correct?
Consider three ANSI-C programs:
P1: #include <stdio.h>Which statement is true?
int a=5;
int main(){ int a=7; return(0); }
P2: #include <stdio.h>
int main(){ int a=5; int a=7; return(0); }
P3: #include <stdio.h>
int main(){ int a=5; float a=7; return(0); }
Two concurrent DBMS transactions \(T_1,T_2\) both access a data object \(A\). For them not to conflict on \(A\), which statement must be true?
A 4-million-byte file is transferred between hosts across three consecutive links of bandwidth 2 Mbps, 500 kbps, and 1 Mbps. Processing and propagation delays, background traffic, and additional overhead are negligible. What is the total transfer time in seconds? Use \(1M=10^6,\ 1k=10^3\).
Which one of the following protocols may need to broadcast some of its messages?
Which one of the following CPU scheduling algorithms cannot be preemptive?
Consider \(n^{1/3},\log n,\log(n!),2^{\log n}\) for positive integer \(n\), with logarithm base 2. Which option lists them in increasing asymptotic growth rate?
Which recurrence relation(s) can correspond to an algorithm with time complexity \(\Theta(n)\)?
Let \(R\) be a binary relation on \(\{1,2,\ldots,10\}\), where \((x,y)\in R\) if \(xy\) is the square of an integer. Which properties are satisfied?
For real \(a\), let \(I(a)=\int_{-1}^{1}(3x^2-ax+1)\,dx\). Which statements are true?
Numbers use 4-bit two's complement. Let \(N_1=1011,\ N_2=1101,\ N_3=1010,\ N_4=1001\). Which operations result in arithmetic overflow?
Which of the following grammars are ambiguous?
The keys \(5,28,19,15,26,33,12,17,10\) are inserted into a hash table using \(h(k)=k\bmod9\). Collisions are resolved by chaining. After insertion, the length of the longest chain is . (Answer in integer.)
Consider \(ax+y=b\) and \(16x+ay=24\). Suppose \(a,b\) are chosen so the system produces multiple solutions. Then the product \(ab\) is . (Answer in integer.)
Merge sort is executed on \(A=[10,7,8,19,41,35,25,31]\) in increasing order, making seven merges. A merge of sorted left \(L\) and right \(R\) is void if its output is the elements of \(L\) followed by those of \(R\). How many of the seven merges are void? (Answer in integer.)
An IP network uses subnet mask \(255.255.240.0\). What is the maximum number of IP addresses that can be assigned to network interfaces? (Answer in integer.)
The 32-bit IEEE 754 single-precision representation of a number is \(0xC2710000\). The number in decimal representation is . (Rounded off to two decimal places.)
A lexical analyzer uses \(\text{letter}\to[A-Za-z]\), \(\text{digit}\to[0-9]\), \(id\to\text{letter}(\text{letter}\mid\text{digit})^*\), \(\text{number}\to\text{digit}^+\), and \(ws\to(\text{blank}\mid\text{tab}\mid\text{newline})^+\). For the string \(x1\ 23mm\ 78\ y\ 7z\ zz5\ 14A\ 8H\ AaYcD\), how many tokens excluding \(ws\) are produced? (Answer in integer.)
Consider a complete graph \(K_n\) with \(n\) vertices (\(n>4\)). Each spanning tree is represented as a set of edges. The Jaccard coefficient of two sets is the size of their intersection divided by the size of their union. What is the lowest possible Jaccard coefficient between two spanning trees of \(K_n\)?
Let \(G\) be a weighted directed acyclic graph with \(m\) edges and \(n\) vertices. Given a source \(s\), what is the worst-case time complexity of the fastest algorithm for shortest-path lengths from \(s\) to all reachable vertices?
For an integer array \(A[1..n]\), check whether for every \(i,j\in\{1,\ldots,n-1\}\) with \(i>j\), \((A[i+1]-A[i])>(A[j+1]-A[j])\). What is the worst-case complexity of the fastest algorithm?
A dynamic-programming table has \(T[0][k]=T[k][0]=1\) and \(T[i][j]=2T[i-1][j]+3T[i][j-1]\) for \(1\le i,j\le n\). Algorithm \(B_1\) fills rows with nested \(i=1..n, j=1..n\). Algorithm \(B_2\) processes sums \(s=2..2n\), scanning all \(i,j\) and updating when \(i+j=s\). All entries are initially 1. Which statement is true?
For \(F(A,B,C,D)=\Sigma m(0,1,2,3,8,9,10,11)\), with \(A\) the MSB and \(D\) the LSB, find the minimal sum-of-products form. Here \(+\), \(\cdot\), and prime denote OR, AND, and NOT.
For canonical LR(0) parsing of \(S\to ACB\), \(A\to aA\mid\epsilon\), \(C\to cC\mid\epsilon\), and \(B\to bB\mid b\), how many shift-reduce conflicts occur in the LR(0) ACTION table?
Armstrong's axioms are Reflexivity, Augmentation, and Transitivity. The Union rule says: if \(X\to Y\) and \(X\to Z\), then \(X\to YZ\). Which listed combination of axioms is both necessary and sufficient to prove Union?
Data bits \(110001011\) are sent using CRC with generator pattern \(1001\). Which remainder pattern is appended before transmission?
A processor has 16 registers and 16-bit instructions with variable-sized opcodes. M-type has two register operands and a 6-bit immediate; R-type has three register operands; C-type has one register and a 6-bit offset. There are two M-type and seven R-type opcodes. What is the maximum number of C-type opcodes?
Consider the following control-flow graph. Which option gives the live-variable set at the exit of each basic block?
A dense index has an entry for every search-key value. Consider S1: a hash index must be dense; S2: a \(B^+\)-tree index can be sparse. Which option is correct?
Consider the two finite automata \(D_1\) and \(D_2\) shown. Which statements are true?
Let \(L=\{a^i b^j c^k d^\ell\mid i,j,k,\ell\ge0\}\). Which constraints ensure that the resulting language is context-free?
A BST has \(n>0\) leaf nodes and distinct real keys. For every leaf \(L_i\) with a non-NULL inorder successor, insert a key \(k_i\) satisfying \(Val(L_i)<k_i<Val(Suc(L_i))\). Let \(K\) be the list of these keys. Which statements are true?
Elements 1,2,3,4,5 arrive in order and are each assigned to an initially empty stack \(S\) or queue \(Q\). After all arrive, the stack is completely popped, then the queue completely dequeued. The output is 4 3 1 2 5. Which assignments are possible?
Three processes execute atomically per line: Wait(A); Print(*); X=X+1; if X==2 then Print($), Signal(B); Signal(A); Wait(B); Print(#); Signal(B). Binary semaphores start \(A=1,B=0\), and shared \(X=0\). Which output patterns are possible?
A 4 KB direct-mapped cache has 16-byte blocks and starts empty. In 16 MB physical memory, words P=0x845B32, Q=0x845B26, R=0x845B36, S=0x846B32 are accessed in order P,Q,R,S, repeated ten times. Which statements are true?
A linked-list free-space scheme is used for a 16 GB disk with 2 KB blocks and 32-bit block numbers. Each list block reserves one 4-byte pointer to the next block. How many blocks are required to hold the free disk block numbers? Use \(1K=2^{10}\), \(1G=2^{30}\).
A TLB has reach 1 MB and page size 4 KB. Virtual address space is 64 GB and physical address space 1 GB. Each entry stores a 4-bit process ID, page number, frame number, and 2 control bits. Find the TLB size in bytes.
Eight nonadjacent holes have sizes 20, 4, 25, 18, 7, 9, 15, and 12 KB. Processes P1=16 KB and P2=9 KB arrive in order and use best fit. After allocation, how many holes are smaller than 8 KB?
A byte-addressed system has 1 MB physical memory and a direct-mapped cache. Physical address 0xA2C28 maps to cache block number \(176_{10}\). What is the maximum possible cache size in KB?
A non-pipelined unit at 1.6 GHz averages 5 cycles per instruction. A pipelined version at 1.2 GHz targets CPI 1, but 30% of instructions incur a 2-cycle stall. Find its speed-up, rounded to two decimal places.
A new TCP connection has receiver window 48 KB, MSS 2 KB, and slow-start threshold 16 KB. With no loss, how many transmission rounds are required to reach congestion avoidance?
The shown active-high 2:4 decoder and 4-to-1 multiplexer have inputs A,B and selects \(S_1,S_0\). Of the 16 input combinations \([A\ B\ S_1\ S_0]\), how many produce \(Y=1\)?
For the ANSI-C code
int *ptr, a, b, c; a=5; b=11; c=20; ptr=&a; *ptr=c; ptr=&c; a=*(&b); c=*ptr-a; printf(\"%d\",c);what integer is printed?
A recursive C function sets \(length=end+1-start\), returns 0 for invalid/negative bounds, and otherwise: if \(length\bmod3=0\), calls \(func(start+1,end)\); if remainder 1, returns \(1+func(start,end-1)\); if remainder 2, calls \(func(start+2,end)\). What maximum value can it return?
A \(4\times4\) matrix \(A\) has determinant 3. Find \(\det(2A)\).
An unbiased coin is tossed six independent times. \(E_1\): at least two heads among tosses 2,4,6. \(E_2\): equal heads and tails among tosses 1,2,3,5. Find \(P(E_1\mid E_2)\), rounded to one decimal place.
For \(r\in(0,1)\), let \(f(r)=1\) when the second digit after the decimal point is 2,3,6, or 7, and 0 otherwise. At how many points in \((0,1)\) is \(f\) discontinuous?
A lossless 3000 km link has bandwidth \(10^8\) bits/s and propagation delay 5 ns/m. Every transmitted data byte has a unique sequence number. Find the minimum sequence-number field width \(N\) so numbers do not wrap within 60 s and maximum link utilization is achieved.
GATE 2026 CS-2 Exam Pattern and Marking Scheme Explained
The official IIT Guwahati master-paper and answer-key page says the key matches the master order, although a candidate's console may have shown a different order.
- Total: 65 questions, 100 marks, and a three-hour CBT in English.
- CS-2 master-key mix: 35 MCQs, 11 MSQs, and 19 NAT questions.
- Marks: General Aptitude carries 15 marks, Engineering Mathematics 13, and the CS core 72.
- Negative marking: wrong one- and two-mark MCQs lose 1/3 and 2/3 respectively. MSQ and NAT have no negative marking; MSQ has no partial credit.
- Calculator: the test supplies an on-screen virtual scientific calculator, not a physical one.
High-Weightage Areas in the GATE 2026 CS-2 Master Paper
The 65 tagged rows show a substantial numerical and systems component, with 19 NAT questions in the official key.
- General Aptitude: 10 questions.
- Engineering Mathematics: 9 questions.
- Programming and Data Structures: 8 questions, including C pointers and recursion.
- Computer Organization, Networks, and Algorithms: 6 questions in each mapped subject.
- Digital Logic: 5 questions, including decoder/multiplexer and Boolean reasoning.
GATE 2026 February 8 Aptitude Solution Video for Both Shifts
Source: Shrenik Jain
How to Use the GATE 2026 CS-2 Question Paper for Practice
Set a 180-minute timer, solve without referring to the key, then use the solutions PDF and per-question links to reconstruct the method behind every miss.
- Track NAT precision and rounding separately from MCQ guessing.
- Rework cache, TCP, compiler, automata, and C-program traces from first principles.
- Check answers by master-paper question number; console question order may differ.
GATE 2026 CS-2 Question Paper with Solutions FAQs
Ques. Was GATE 2026 CS-2 difficult or lengthy?
Ans. Reactions varied, but candidates described several logic-intensive and time-consuming questions. The official CS-2 key has 19 NATs and 11 MSQs, so calculation and multi-select accuracy materially affect time management.
Ques. How many questions were asked in GATE 2026 CS-2?
Ans. CS-2 had 65 questions for 100 marks over three hours. The master key classifies them as 35 MCQs, 11 MSQs, and 19 NAT questions.
Ques. What was the GATE 2026 CS qualifying cut-off?
Ans. The official CS cut-off is 30 for General, 27 for OBC-NCL/EWS, and 20 for SC/ST/PwD. Crossing it qualifies a candidate but does not by itself secure admission.
Ques. Is there negative marking for GATE CS MSQ and NAT?
Ans. No. Only wrong MCQs incur negative marks. An MSQ still requires every correct choice and no incorrect choice for full marks, with no partial credit.
Ques. Where can I download the official GATE 2026 CS-2 question paper and answer key?
Ans. The study question and solution PDFs are linked above. IIT Guwahati hosts the official CS-2 master paper and key on the GATE 2026 website.








Comments