All subjects · 4 December 2026
GATE CS 2027 | 25-30 Questions Daily - 04-12-2026
GATE CS 2027 | 25-30 Questions Daily - 04-12-2026 - www.gateiit.in
25 questions · PDF 126 KB · practise free, log in to save answers and take the timed exam · GATE CSE syllabus
Engineering Mathematics
Question 1HardMCQ · 1 mark
A laboratory has 8 distinct components to be distributed among 4 labelled containers C1, C2, C3 and C4. The distribution must satisfy all of the following: • Every container receives at least one component. • C1 receives an odd number of components. • C2 receives at least two components. • C3 receives at most three components. • C4 receives an even number of components. How many valid distributions are possible?
Log in to save your answerCheck answer opens 5 Dec, 12:00 am ISTQuestion 2MSQ · 1 marklinear-algebra
Consider the system A(λ) x = b, where b = (1, 2, 3, 4) written as a column vector, and A(λ) is the 4 × 4 matrix whose rows are: Row Column 1 Column 2 Column 3 Column 4 1 1 1 1 1 2 1 2 3 4 3 1 3 6 10 4 1 4 10 λ Which of the following statements are correct?
Log in to save your answerCheck answer opens 5 Dec, 12:00 am ISTQuestion 3AIR 1 ChallengeMCQ · 1 markprobability-and-statistics
Three independent components have exponentially distributed lifetimes: X1 with rate λ, X2 with rate 2λ and X3 with rate 3λ, where λ > 0. Let T be the lifetime of the first component to fail, and let J be the index of that component. Given that the first failure occurs before time t > 0, find the conditional probability P( J = 2 | T < t ) that component 2 is the first to fail.
Log in to save your answerCheck answer opens 5 Dec, 12:00 am IST
Digital Logic
Question 4MSQ · 1 mark
A combinational circuit has three outputs F1, F2 and F3 defined over four inputs A, B, C and D, with the following ON-sets (sums of minterms, A being the most significant variable): F1 = Σm(0, 2, 5, 7, 8, 10, 13, 15) F2 = Σm(0, 1, 4, 5, 10, 11, 14, 15) F3 = Σm(2, 3, 6, 7, 8, 9, 12, 13) The common don’t-care set is d = Σm(1, 3, 9, 11). A minterm that appears both in an ON-set and in d is treated as an ON-set minterm of that output. Each output may use any subset of the don’t- care minterms independently. The implementation cost is the total number of distinct product terms over all three outputs, where a product term shared by several outputs is counted once. Which of the following statements are correct?
Log in to save your answerCheck answer opens 5 Dec, 12:00 am ISTQuestion 5AIR 1 ChallengeMCQ · 1 mark
A synchronous sequential circuit has two D flip-flops with outputs Q1 and Q0, an input X, and the following equations: D1 = Q1 XOR X D0 = Q0 XOR (Q1 AND X) The output is Y = Q1 XOR Q0. The circuit is initialized to Q1 Q0 = 00, and the input is applied synchronously. The input sequence is periodic: the 8-bit pattern 1, 1, 0, 1, 0, 0, 1, 1 is repeated indefinitely. What is the minimum positive number of clock cycles after which the complete sequence of states and outputs begins repeating with the same phase of the input pattern?
Log in to save your answerCheck answer opens 5 Dec, 12:00 am IST
Computer Organization and Architecture
Question 6MSQ · 1 markprogramming-data-structures-and-algorithms
A processor has a microprogrammed control unit with a control memory of 128 microinstructions. Each microinstruction word is 64 bits wide, but only the following four fields are considered, each using the minimum number of bits required: • Control-signal field: there are 32 control signals, encoded in a 1-of-32 (one-hot) form, that is, one bit per control signal. • Condition-selection field: it must distinguish 4 conditions plus an unconditional choice. • Next-address field: it must be able to address any microinstruction directly. • Sequencing-control field: it selects one of exactly 3 operations, namely sequential execution, conditional branch and opcode mapping. Which of the following statements are necessarily TRUE?
Log in to save your answerCheck answer opens 5 Dec, 12:00 am ISTQuestion 7AIR 1 ChallengeMCQ · 1 mark
A processor uses a 5-stage pipeline with the stages IF, ID, EX, MEM and WB, with the following properties: • Every instruction spends one cycle in each stage, unless it is stalled. • There is no forwarding. Registers are read in ID and written in WB, and a register written in WB can be read in ID in the same cycle. • A dependent instruction stays in ID until its source registers can be read. • Instruction and data memories are separate, and there are no structural hazards. • A branch is resolved in EX and prediction is always not-taken. When a branch is taken, the two younger instructions in IF and ID are flushed, and the target instruction is fetched in the cycle immediately after the EX stage of the branch. The instruction sequence is: The branch is taken. How many cycles are required from the start of the IF stage of I1 until I8 completes its WB stage?
I1: ADD R1, R2, R3 I2: LOAD R4, 0(R1) I3: SUB R5, R4, R6 I4: BEQ R5, R0, TARGET I5: ADD R7, R7, R1 I6: MUL R8, R7, R2 TARGET: I7: XOR R9, R4, R5 I8: STORE R9, 4(R1)Log in to save your answerCheck answer opens 5 Dec, 12:00 am IST
Programming and Data Structures
Question 8HardMCQ · 1 markprogramming-data-structures-and-algorithms
Consider the following C program: What is the output? (The first line of each option is the first line printed, and the second line is the second line printed.)
#include <stdio.h> int f(int *p, int n) { if (n <= 1) return *p; int x = f(p + 1, n - 1); *p = *p + x % 5; return *p - x; } int main() { int a[] = {13, 8, 11, 6, 9}; int *p = a + 1; int r = f(p, 4); printf("%d\n", r); for (int i = 0; i < 5; i++) printf("%d ", a[i]); return 0; }Log in to save your answerCheck answer opens 5 Dec, 12:00 am ISTQuestion 9MSQ · 1 markprogramming-data-structures-and-algorithms
A binary tree with distinct integer keys has the following traversals: Preorder: 1, 2, 4, 5, 3, 6, 7 Postorder: 4, 5, 2, 6, 7, 3, 1 Assume that the tree is a full binary tree, that is, every node has either zero or two children. Which of the following statements are necessarily TRUE?
Log in to save your answerCheck answer opens 5 Dec, 12:00 am ISTQuestion 10AIR 1 ChallengeMCQ · 1 markprogramming-data-structures-and-algorithms
Consider a directed graph with the vertices 1, 2, 3, 4, 5, 6 and 7, and the following directed edges: (1,2), (1,3), (2,4), (2,5), (3,5), (3,6), (4,1), (4,7), (5,4), (5,6), (6,3), (6,7), (7,5) Recursive DFS is run with the standard discovery and finishing times. The outer loop considers the vertices in increasing order, and the outgoing edges of each vertex are scanned in increasing order of the destination vertex. What is the number of back edges in the resulting DFS forest?
Log in to save your answerCheck answer opens 5 Dec, 12:00 am IST
Algorithms
Question 11HardMCQ · 1 markprogramming-data-structures-and-algorithms
A directed weighted graph has 5 vertices, numbered 1 to 5. The entry in row i and column j of the following table is the cost of the edge from vertex i to vertex j, where ∞ means that there is no such edge: From \ To 1 2 3 4 5 1 0 4 2 ∞ 7 2 ∞ 0 5 3 ∞ 3 ∞ 1 0 6 4 4 2 ∞ ∞ 0 3 5 ∞ 2 ∞ 1 0 A cycle must start at vertex 1, visit every other vertex exactly once and return to vertex 1. The cost of a cycle is the sum of its edge costs. What is the minimum cost of such a cycle?
Log in to save your answerCheck answer opens 5 Dec, 12:00 am ISTQuestion 12MSQ · 1 markprogramming-data-structures-and-algorithms
Consider the following deterministic quicksort implementation, where swap exchanges the two array elements whose addresses are given: Which of the following statements are correct?
int partition(int a[], int l, int r) { int pivot = a[r]; int i = l - 1; for (int j = l; j < r; j++) { if (a[j] <= pivot) { i++; swap(&a[i], &a[j]); } } swap(&a[i+1], &a[r]); return i+1; } void quicksort(int a[], int l, int r) { if (l < r) { int p = partition(a, l, r); quicksort(a, l, p-1); quicksort(a, p+1, r); } }Log in to save your answerCheck answer opens 5 Dec, 12:00 am ISTQuestion 13AIR 1 ChallengeMCQ · 1 markprogramming-data-structures-and-algorithms
Consider the following directed weighted graph with the source vertex S: Edge Weight S → A 4 S → B 5 A → B −2 B → C 3 C → A −2 A → D 6 C → D 2 D → E 1 The Bellman-Ford algorithm is executed from S. Which of the following statements correctly describes the result?
Log in to save your answerCheck answer opens 5 Dec, 12:00 am IST
Theory of Computation
Question 14MSQ · 1 mark
Consider the following language over the alphabet {0, 1}: L = { w | #0(w) is divisible by 3 and #1(w) is divisible by 2 } where #a(w) is the number of occurrences of the symbol a in w. Which of the following statements are correct?
Log in to save your answerCheck answer opens 5 Dec, 12:00 am ISTQuestion 15MCQ · 1 mark
Consider the following languages: L = { ai bj ck | i = j or j = k, where i, j, k ≥ 0 } Leq = { an bn cn | n ≥ 0 } Which one of the following statements is correct?
Log in to save your answerCheck answer opens 5 Dec, 12:00 am IST
Compiler Design
Question 16MSQ · 1 mark
Consider the following grammar: E → E + T | T T → T * F | F F → ( E ) | id The following translation rules are used: • E → E1 + T: E.place = newtemp(), and the instruction E.place = E1.place + T.place is emitted. • T → T1 * F: T.place = newtemp(), and the instruction T.place = T1.place * F.place is emitted. • F → id: F.place = id.lexeme. • F → ( E ): F.place = E.place. The input is: a + b * (c + d) * e. Both operators are left associative, no algebraic simplification is done, and the temporaries are allocated in the order in which the instructions are emitted. Which of the following statements are correct?
Log in to save your answerCheck answer opens 5 Dec, 12:00 am ISTQuestion 17MCQ · 1 markcalculus-and-optimization
Consider the following basic block, in which all variables are integers: The compiler performs local common subexpression elimination, constant propagation and dead- code elimination, but not copy propagation. An expression can be reused only if its operands have not been modified since it was previously computed. There is no overflow, and input() and print() are observable operations. What is the number of statements remaining after optimization, counting only assignment and output statements?
1. a = input(); 2. b = 10; 3. c = a + b; 4. d = c * 2; 5. e = a + b; 6. b = 20; 7. f = e + b; 8. g = d + f; 9. print(g);Log in to save your answerCheck answer opens 5 Dec, 12:00 am IST
Operating Systems
Question 18MCQ · 1 mark
Three processes execute the following code. Initially x = 0, and the semaphores are initialized as shown: Semaphore operations and assignments are atomic, execution is sequentially consistent, and the scheduling of enabled processes is fair. Which of the following statements are correct?
semaphore S = 1; semaphore A = 0; semaphore B = 0; Process P1: Process P2: Process P3: wait(S); wait(A); wait(S); x = x + 2; x = x + 5; x = x + 7; signal(A); signal(B); signal(S); wait(B); x = x * 3; signal(S);Log in to save your answerCheck answer opens 5 Dec, 12:00 am ISTQuestion 19NAT · 1 mark
A computer uses a 32-bit virtual address and a 4-level page table. The page size is 4 KB and each page table entry is 4 bytes. The bits of the virtual address other than the page offset are divided equally among the four levels. The system has a fully associative TLB with 64 entries, a TLB lookup time of 10 ns, a main- memory access time of 80 ns and a TLB hit ratio of 90%. The TLB lookup is sequential with the memory access. A TLB miss requires four memory accesses for the page table walk, followed by one memory access for the data. Ignore page faults and all other overheads. Calculate the effective memory access time in nanoseconds. (Give your answer as an integer.) Answer: ____________
Log in to save your answerCheck answer opens 5 Dec, 12:00 am ISTQuestion 20AIR 1 ChallengeMCQ · 1 mark
A system uses preemptive Shortest Remaining Processing Time (SRPT) scheduling for the CPU, with zero context-switch overhead. At every arrival or I/O completion, the process with the shortest remaining CPU time runs, and ties are broken in favour of the process that is already running. The completion time of a process is the time at which it finishes its last CPU unit. The processes are: Total CPU Process Arrival TimeTime P1 0 8 P2 1 4 P3 2 3 P1 issues an I/O request that takes 5 time units after executing its first 3 CPU units, and needs its remaining 5 CPU units after the I/O completes. P2 and P3 do no I/O. A file system uses indexed allocation in which each index block stores 256 data-block addresses, and a new index block is allocated when the previous one is full. A file occupies 257 data blocks. Which of the following statements is correct?
Log in to save your answerCheck answer opens 5 Dec, 12:00 am IST
Database Management Systems
Question 21MSQ · 1 markcalculus-and-optimization
Consider the schema STUDENT(SID, Name), COURSE(CID, Dept) and ENROLL(SID, CID, Grade). SID and CID are the primary keys of STUDENT and COURSE, (SID, CID) is the primary key of ENROLL, every grade is an integer from 0 to 100 or NULL, and every course belongs to exactly one department. A NULL grade does not violate the condition Grade ≥ 60. A student qualifies if the student is enrolled in every course of the CSE department, and none of the student’s CSE-course enrollments has a non-NULL grade below 60. Which of the following statements correctly express this requirement?
Log in to save your answerCheck answer opens 5 Dec, 12:00 am ISTQuestion 22NAT · 1 markdatabase-management-and-warehousing
Consider the relation R(A, B, C, D, E, F, G) with the following functional dependencies: { A → BC, CD → E, E → D, B → F, F → G, G → A } Find the total number of distinct candidate keys of R. (Give your answer as an integer.) Answer: ____________
Log in to save your answerCheck answer opens 5 Dec, 12:00 am ISTQuestion 23AIR 1 ChallengeMCQ · 1 markdatabase-management-and-warehousing
Consider the following three transactions, where Ri(X) and Wi(X) denote a read and a write of X by transaction Ti: T1: R1(X), W1(X), R1(Y) T2: R2(Y), W2(Y), R2(Z), W2(Z) T3: R3(Z), W3(Z), R3(X), W3(X) They are executed in the following schedule S: R1(X), R2(Y), R3(Z), W1(X), W2(Y), W3(Z), R1(Y), R2(Z), R3(X), W2(Z), W3(X) Strict two-phase locking (strict 2PL) is used: locks are acquired during a growing phase and exclusive locks are held until the transaction commits. Which of the following statements is correct?
Log in to save your answerCheck answer opens 5 Dec, 12:00 am IST
Computer Networks
Question 24MSQ · 1 mark
An IPv4 datagram of total length 4020 bytes, including a 20-byte header and no options, passes through two consecutive links with MTUs of 1500 bytes and 620 bytes. Fragmentation is permitted at both routers, every fragment has a 20-byte IPv4 header, and the Identification field is unchanged. Which of the following statements are correct after the datagram crosses the second link?
Log in to save your answerCheck answer opens 5 Dec, 12:00 am ISTQuestion 25AIR 1 ChallengeMCQ · 1 mark
A TCP sender has the following state: • MSS = 1000 bytes, congestion window = 7000 bytes, and receiver advertised window = 9000 bytes. • The next sequence number to be sent is 12001, the oldest unacknowledged byte has sequence number 5001, and the receiver has cumulatively acknowledged all bytes up to 5000. • The sender always has more application data to send. There are no retransmissions or SACK information. The sender now receives a cumulative ACK acknowledging all bytes up to sequence number 8000, and the new advertised window of the receiver is 6000 bytes. The congestion window remains unchanged. What is the maximum number of additional bytes that the sender can transmit immediately after processing this ACK, without violating the congestion window or the receiver window?
Log in to save your answerCheck answer opens 5 Dec, 12:00 am IST
More daily sets
- 2026-12-03GATE CS 2027 | 25-30 Questions Daily - 03-12-2026
- 2026-12-02GATE CS 2027 | 25-30 Questions Daily - 02-12-2026
- 2026-12-01GATE CS 2027 | 25-30 Questions Daily - 01-12-2026
- 2026-11-30GATE CS 2027 | 25-30 Questions Daily - 30-11-2026
- 2026-11-29GATE CS 2027 | 25-30 Questions Daily - 29-11-2026
- 2026-11-28GATE CS 2027 | 25-30 Questions Daily - 28-11-2026
- 2026-11-27GATE CS 2027 | 25-30 Questions Daily - 27-11-2026
- 2026-11-26GATE CS 2027 | 25-30 Questions Daily - 26-11-2026