GATE 2018 CS – Previous Year Questions with Solutions
All 65 questions of GATE 2018 CS 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 – "From where are they bringing their books? bringing books from ." The words that best fill the blanks in the above sentence are
- Question 2 – "A investigation can sometimes yield new facts, but typically organized ones are more successful." The word that best fills the blank in the above…
- Question 3 – The area of a square is d. What is the area of the circle which has the diagonal of the square as its diameter?
- Question 4 – What would be the smallest natural number which when divided either by 20 or by 42 or by 76 leaves a remainder of 7 in each case?
- Question 5 – What is the missing number in the following sequence? 2, 12, 60, 240, 720, 1440, , 0
- Question 6 – In appreciation of the social improvements completed in a town, a wealthy philanthropist decided to gift Rs 750 to each male senior citizen in the…
- Question 7 – If pqr0 and p-x=1q, q-y=1r, r-z=1p, what is the value of the product xyz?
- Question 8 – In a party, 60% of the invited guests are male and 40% are female. If 80% of the invited guests attended the party and if all the invited female…
- Question 9 – In the figure below, DEC+ BFC is equal to . (The four options are given in terms of the angles marked in the figure.)
- Question 10 – A six sided unbiased die with four green faces and two red faces is rolled seven times. Which of the following combinations is the most likely outcome…
- Question 11 – Which one of the following is a closed form expression for the generating function of the sequence \a n\, where a n=2n+3 for all n=0,1,2,?
- Question 12 – Consider the following C program. The output of this program is:
- Question 13 – A queue is implemented using a non-circular singly linked list. The queue has a head pointer and a tail pointer, as shown in the figure. Let n denote…
- Question 14 – Let and denote the Exclusive OR and Exclusive NOR operations, respectively. Which one of the following is NOT CORRECT?
- Question 15 – Consider the following processor design characteristics. I. Register-to-register arithmetic operations only II. Fixed-length instruction format III.…
- Question 16 – Let N be an NFA with n states. Let k be the number of states of a minimal DFA which is equivalent to N. Which one of the following is necessarily…
- Question 17 – The set of all recursively enumerable languages is
- Question 18 – Which one of the following statements is FALSE?
- Question 19 – The following are some events that occur after a device controller issues an interrupt while process L is under execution. (P) The processor pushes…
- Question 20 – Consider a process executing on an operating system that uses demand paging. The average time for a memory access in the system is M units if the…
- Question 21 – In an Entity-Relationship (ER) model, suppose R is a many-to-one relationship from entity set E1 to entity set E2. Assume that E1 and E2 participate…
- Question 22 – Consider the following two tables and four queries in SQL. Book (isbn, bname), Stock (isbn, copies) Query 1: SELECT B.isbn, S.copies FROM Book B INNER…
- Question 23 – Match the following: Field Length in bits --- --- P. UDP Header's Port Number I. 48 Q. Ethernet MAC Address II. 8 R. IPv6 Next Header III. 32 S. TCP…
- Question 24 – Consider the following statements regarding the slow start phase of the TCP congestion control algorithm. Note that cwnd stands for the TCP congestion…
- Question 25 – Two people, P and Q, decide to independently roll two identical dice, each with 6 faces, numbered 1 to 6. The person with the lower number wins. In…
- Question 26 – The value of 0/4x(x2)\,dx correct to three decimal places (assuming that =3.14) is .
- Question 27 – Consider a matrix A=uvT where u=pmatrix1\\2pmatrix, v=pmatrix1\\1pmatrix. Note that vT denotes the transpose of v. The largest eigenvalue of A is .
- Question 28 – The chromatic number of the following graph is .
- Question 29 – Let G be a finite group on 84 elements. The size of a largest possible proper subgroup of G is .
- Question 30 – The postorder traversal of a binary tree is 8,9,6,7,4,5,2,3,1. The inorder traversal of the same tree is 8,6,9,4,7,2,5,1,3. The height of a tree is…
- Question 31 – Consider the following C program: The output of this program is .
- Question 32 – Consider the sequential circuit shown in the figure, where both flip-flops used are positive edge-triggered D flip-flops (a serial chain with input…
- Question 33 – A 32-bit wide main memory unit with a capacity of 1 GB is built using 256M 4-bit DRAM chips. The number of rows of memory cells in the DRAM chip is…
- Question 34 – Consider a system with 3 processes that share 4 instances of the same resource type. Each process can request a maximum of K instances. Resource…
- Question 35 – Consider a long-lived TCP session with an end-to-end bandwidth of 1 Gbps (=109 bits-per-second). The session starts with a sequence number of 1234.…
- Question 36 – Consider a matrix P whose only eigenvectors are the multiples of bmatrix1\\4bmatrix. Consider the following statements. (I) P does not have an inverse…
- Question 37 – Let N be the set of natural numbers. Consider the following sets. P: Set of Rational numbers (positive and negative) Q: Set of functions from \0,1\ to…
- Question 38 – Consider the first-order logic sentence s\, t\, u\, v\, w\, x\, y\ (s,t,u,v,w,x,y) where (s,t,u,v,w,x,y) is a quantifier-free first-order logic…
- Question 39 – Consider the following C program: The output of the program above is
- Question 40 – Let G be a simple undirected graph. Let T D be a depth first search tree of G. Let T B be a breadth first search tree of G. Consider the following…
- Question 41 – Assume that multiplying a matrix G 1 of dimension p q with another matrix G 2 of dimension q r requires pqr scalar multiplications. Computing the…
- Question 42 – Consider the following C code. Assume that `unsigned long int` type length is 64 bits. The value returned when we call `fun` with the input 240 is
- Question 43 – Consider the unsigned 8-bit fixed point binary number representation below, b 7b 6b 5b 4b 3.b 2b 1b 0 where the position of the binary point is…
- Question 44 – The size of the physical address space of a processor is 2P bytes. The word length is 2W bytes. The capacity of cache memory is 2N bytes. The size of…
- Question 45 – Consider the following languages: I. \ambncpdq m+p=n+q,\ where m,n,p,q0\ II. \ambncpdq m=n and p=q,\ where m,n,p,q0\ III. \ambncpdq m=n=p and p q,\…
- Question 46 – Consider the following problems. L(G) denotes the language generated by a grammar G. L(M) denotes the language accepted by a machine M. (I) For an…
- Question 47 – A lexical analyzer uses the following patterns to recognize three tokens T 1, T 2, and T 3 over the alphabet \a,b,c\. T 1: a?(b c)*a T 2: b?(a c)*b T…
- Question 48 – Consider the following parse tree for the expression `a#b\c\d#e#f`, involving two binary operators `\` and `#`. Which one of the following is correct…
- Question 49 – In a system, there are three types of resources: E, F and G. Four processes P 0, P 1, P 2 and P 3 execute concurrently. At the outset, the processes…
- Question 50 – Consider the following solution to the producer-consumer synchronization problem. The shared buffer size is N. Three semaphores empty, full and mutex…
- Question 51 – Consider the relations r(A,B) and s(B,C), where s.B is a primary key and r.B is a foreign key referencing s.B. Consider the query Q:\ r( B<5(s)) Let…
- Question 52 – Consider the following four relational schemas. For each schema, all non-trivial functional dependencies are listed. The underlined attributes are the…
- Question 53 – Let G be a graph with 100! vertices, with each vertex labelled by a distinct permutation of the numbers 1,2,,100. There is an edge between vertices u…
- Question 54 – Consider Guwahati (G) and Delhi (D) whose temperatures can be classified as high (H), medium (M) and low (L). Let P(H G) denote the probability that…
- Question 55 – Consider the following program written in pseudo-code. Assume that `x` and `y` are integers. The number of times that the `print` statement is…
- Question 56 – The number of possible min-heaps containing each value from \1,2,3,4,5,6,7\ exactly once is .
- Question 57 – Consider the following undirected graph G (the edge weights are shown in the figure, with one edge of unknown weight x): Choose a value for x that…
- Question 58 – Consider the weights and values of items listed below. Note that there is only one unit of each item. Item number Weight (in Kgs) Value (in Rupees)…
- Question 59 – Consider the minterm list form of a Boolean function F given below. F(P,Q,R,S)= m(0,2,5,7,9,11)+d(3,8,10,12,14) Here, m denotes a minterm and d…
- Question 60 – The instruction pipeline of a RISC processor has the following stages: Instruction Fetch (IF), Instruction Decode (ID), Operand Fetch (OF), Perform…
- Question 61 – A processor has 16 integer registers (R0, R1, ..., R15) and 64 floating point registers (F0, F1, ..., F63). It uses a 2-byte instruction format. There…
- Question 62 – Given a language L, define Li as follows: L0=\\ and Li=Li-1 L for all i>0. The order of a language L is defined as the smallest k such that Lk=Lk+1.…
- Question 63 – Consider a storage disk with 4 platters (numbered as 0, 1, 2 and 3), 200 cylinders (numbered as 0, 1, ..., 199), and 256 sectors per track (numbered…
- Question 64 – Consider an IP packet with a length of 4,500 bytes that includes a 20-byte IPv4 header and a 40-byte TCP header. The packet is forwarded to an IPv4…
- Question 65 – Consider a simple communication system where multiple nodes are connected by a shared broadcast medium (like Ethernet or wireless). The nodes in the…