Professional Documents
Culture Documents
CS - GATE-2019 - Paper - FEB-3-2019 - Morning Session - Memory Based
CS - GATE-2019 - Paper - FEB-3-2019 - Morning Session - Memory Based
CS
Engineering
Mathematics
General Aptitude
7%
15%
Operating System
10%
Compiler Design
Programming and
8%
Data Structures
9%
Computer Networks
6%
Design and Analysis
Data Base of Algorithm
Management System 7%
7%
Discrete Mathematics
Digital Logic and Graph Theory
8% 11%
Theory of Computer
Computation Organization and
6% Architecture
6%
Don’t Wait! Know Your GATE Rank with GATE Rank Predictor. Predict Now, http://bit.ly/grp2019
: 080-4061 1000, info@thegateacademy.com ©Copyright reserved. Web:www.thegateacademy.com
1
ME-
CS
CS ANALYSIS-2019_Feb-3_Morning
Level of Total
SUBJECT No. of Ques. Topics Asked in Paper(Memory Based)
Ques. Marks
Engineering 1 Marks: 5
Linear Algebra, Probability , Calculus, Medium 7
Mathematics 2 Marks: 1
1 Marks: 2 CPU Scheduling, Synchronization,
Operating System 2 Marks: 4 Deadlock, Memory Management and File Medium 10
Systems
Programming 1 Marks: 3
and Data 2 Marks: 3 All programming Easy 9
Structures
Design and 1 Marks: 1
Subsequence sum, max heap, MST ,
Analysis of 2 Marks: 3 Easy 7
binary tree
Algorithm
Discrete 1 Marks: 3
Mathematics and 2 Marks: 4 Trees, Graph Theory Medium 11
Graph Theory
Computer 1 Marks: 2
Organization and 2 Marks: 2 Memory Organization Medium 6
Architecture
Theory of 1 Marks:2 Pumping lemma, Countability, Context free
Medium 6
Computation 2 Marks: 2 language
1 Marks: 4 K, Maps, Boolean Algebra, Combinational
Digital Logic Medium 8
2 Marks: 2 Circuits, Number system
Data Base 1 Marks: 3
SQL, B+Tree, Transactions and
Management 2 Marks: 2 Easy 7
Concurrency Control, Relational Algebra
System
Computer 1 Marks: 2
Protocols, Ethernet, Medium 6
Networks 2 Marks: 2
1 Marks: 2
Compiler Design Lexical Analysis Medium 8
2 Marks: 3
1 Marks: 5
General Aptitude Numbers, Data Interpretation, Grammar Medium 15
2 Marks:5
Total 65 100
Don’t Wait! Know Your GATE Rank with GATE Rank Predictor. Predict Now, http://bit.ly/grp2019
: 080-4061 1000, info@thegateacademy.com ©Copyright reserved. Web:www.thegateacademy.com
2
ME-
CS
General Aptitude
GATE 2019 Examination* (Memory Based)
General Aptitude
Q.1 - Q.5 Carry One Mark e
1. The police has arrested four criminals P, Q, R and S.
P says Q committed crime
Q says S committed crime
R says “I didn’t do it”
S says what Q said about me is false.
There is only one criminal and also only one of the above statements is correct. Who among
the four committed the crime?
(A) P
(B) Q
(C) R
(D) S
[Ans. C]
P Q R S
T F T T
F T T F
F F T/F T
In such scenario, we assume one person tells true.
If P is telling true, Q will automatically be false and if Q is false then S is automatically true
according to scenario. And R is already telling true. But, here we are gaining 3 persons telling
truth which is not matching our criteria of only one statement being true.
Similarly if Q is telling true, means P is telling false. And if Q is true then S is automatically be
false. Here also, we are gaining more than one statement to be true.
So, we assume P is telling false, means Q is also telling false means S is automatically telling
true. So, we have two choices for R as true or false. So, R is telling false to match our criteria.
Since R is telling false that he has not done anything means he is the culprit.
Don’t Wait! Know Your GATE Rank with GATE Rank Predictor. Predict Now, http://bit.ly/grp2019
: 080-4061 1000, info@thegateacademy.com ©Copyright reserved. Web:www.thegateacademy.com
3
ME-
CS
2. Two cars start at same place in same direction at same time and covers same distance. Car ‘A’
has speed 50 km/hr, car ‘B’ has speed 60 km/hr. After how many hours the distance between
them will be 20 kms?
[Ans. *]Range: 2 to2
Since both the cars ‘A’ and ‘B’ start at same time from same place.
So, speed of car ‘B’ with respect to car ‘A’ is 10 km/hr
20 km
So, time taken to be a gap of 20 kms between them = = 2 hours.
10 kmph
3. The court is for judge as _________is to teacher.
(A) Syllabus
(B) Punishment
(C) Student
(D) School
[Ans. D]
As court is work-place for judge, similarly school is work-place for teachers.
4. 10 students decide to buy gift for their teacher. After buying gift, 2 of the students do not pay
their share. Then share of the remaining students increases by 150 each. What is the cost of
the gift?
(A) 3000
(B) 6000
(C) 1200
(D) 666
[Ans. B]
As two students did not pay their share for the gift; share of remaining students increased by
Rs.150 each.
⇒ increased money to be paid = 150 ∗ 8 = 1200
This 1200 is nothing but the share of those two students who didn’t pay.
1200
⇒ share of each = = 600, and this is share of every students to be paid
2
∴ total cost = 600 ∗ 10 = 6000
5. There are 80 students are in drama club only, 40 students are in dance club only and 30
students are in math club only. 12 students are both in drama and math club, 7 students are in
dance and math club both, 20 students are in dance and drama club both and 2 students are in
Don’t Wait! Know Your GATE Rank with GATE Rank Predictor. Predict Now, http://bit.ly/grp2019
: 080-4061 1000, info@thegateacademy.com ©Copyright reserved. Web:www.thegateacademy.com
4
ME-
CS
all the clubs. If 75% of the total college students are not part of any club , then the total
number of students in the college are __________
[Ans. *]Range: 740 to 740
Drama Dance
18 40
80
2
10 5
30
Math
Number of students who are part of the clubs= 80 + 40 + 30 + 18 + 5 + 10 + 2 = 185
Since, 75% of the students are not part of any club; means only 25% of the students (185) are
part of the club.
1
∗ total = 185
4
∴ Total students = 185 × 4 = 740
Don’t Wait! Know Your GATE Rank with GATE Rank Predictor. Predict Now, http://bit.ly/grp2019
: 080-4061 1000, info@thegateacademy.com ©Copyright reserved. Web:www.thegateacademy.com
5
CS
20
Researchers
40
(A) 0-15
(B) 16-30
(C) 47-60
(D) 31-46
[Ans. D]
Number of Administrators = 10+20+20=50
Total number of person= 80+20+20+40=160
50 5
So, % of Administrators = ( ) × 100 = × 100 = 31.25%
160 16
Don’t Wait! Know Your GATE Rank with GATE Rank Predictor. Predict Now, http://bit.ly/grp2019
: 080-4061 1000, info@thegateacademy.com ©Copyright reserved. Web:www.thegateacademy.com
6
CS
Technical
Q.1 - Q.25 Carry One Mark each.
1. Let Z = X − Y, X, Y, Z are signed magnitude numbers and X, Y are represented in n-bit numbers.
To avoid overflow minimum number of bits would require for Z is _________
(A) n-bit
(B) n + 2 bits
(C) n + 1 Bits
(D) (n − 1) bits
[Ans. C]
2. From a complete binary tree T of 8 leaf nodes, two leaf nodes a and b are selected randomly and
uniformly. What is the expected distance between a and b in T?
[Ans. *]Range 4.25 to 4.25
N is having 8 leaf nodes.
One leaf with 2 edge distance.
Two leaves with 4 edge distance
Four leaves with 6 edge distance.
Total 7 leaves are here so approximately if we take answer would be in the range of 4.25 to 4.85.
Expectation = (1*2 + 2*4 + 4*6)/N = 34/8 = 4.25 (up to decimal places exact as stated in
question)
Don’t Wait! Know Your GATE Rank with GATE Rank Predictor. Predict Now, http://bit.ly/grp2019
: 080-4061 1000, info@thegateacademy.com ©Copyright reserved. Web:www.thegateacademy.com
7
CS
4. Which of the following are used to send and retrieve emails respectively?
(A) SMTP and IMAP
(B) SMTP and POP3
(C) IMAP and POP3
(D) POP3 and SMTP
[Ans. B]
SMTP & POP3 are the protocols which are responsible for the email communication, SMTP is
responsible for outgoing mail & POP3 is responsible for retrieving mail.
6. In RSA algorithm, the value of n is 3007 and the value of ∅(n) is 2880 where ∅ is the Euler’s
totient function. What is the value of the prime number which greater than 50?
[Ans. *]Range: 97 to 97
A/q to RSA Algorithm
n = p ∗ q & O(n) = (p − 1)(q − 1) (Where p & q are two prime numbers)
So, 97 & 31 are the two prime numbers (which is satisfying the condition) & 97 is greater than
50 so, 97 is the right answer.
7. The chip selects logic for a certain DRAM chip in memory design shown. Assume that memory
has 16 address of memory system (in hexadecimal) that can be enabled by chip select?
(A) CA00 to CAFF
(B) DA00 to DAFF
(C) C800 to CFFF
(D) C800 to C8FF
A15
CS
A11
[Ans. C]
The address lines are given by A15 to A0
A15 1
A14 1
A13 1
CS = 1
A12 1
A11 1
⇒ A15 = A14 = A11 = 1
⇒ A13 = A12 = 0
A15 A14 A13 A12 A11 A10 A9 A8 A7 A6 A5 A4 A3 A2 A1 A0
1 1 0 0 1 x x x x x x x x x x x
Don’t Wait! Know Your GATE Rank with GATE Rank Predictor. Predict Now, http://bit.ly/grp2019
: 080-4061 1000, info@thegateacademy.com ©Copyright reserved. Web:www.thegateacademy.com
8
CS
1 1 0 0 1 0 0 0 0 0 0 0 0 0 0 0
(x=0 starting
address)
⋮
⋮
1 1 0 0 1 1 1 1 1 1 1 1 1 1 1 1
(x=3 ending
address )
(C) L H S = (x + y) ⊕ z
R H S = x ⊕ (y + z)
Xyz LHS RHS
011 0 1
L H S ≠ R H S ⇒ False
(D) L H S = (x ⊕ y) ⊕ z
R H S = x ⊕ (y ⊕ z)
Xyz LHS RHS
011 0 0
As associative ⇒ True
Don’t Wait! Know Your GATE Rank with GATE Rank Predictor. Predict Now, http://bit.ly/grp2019
: 080-4061 1000, info@thegateacademy.com ©Copyright reserved. Web:www.thegateacademy.com
9
CS
9. First order predicate logic x [(∀z ∶ z|x ⇒ ((z = x) ∨ (z = 1))) ⇒ ∃w(w > x)⋀
(∀z ∶ z|w ⇒ ((w = z) ∨ (z = 1)))] ; a|b means a divides b where a, b are integers
For sets
s1 = {1, 2, 3, ⋯ 100}
s2 = set of all positione integers
s3 = set of all integers
Which one of the following satisfies?
(A) s2 and s3
(B) s1 and s2
(C) All of these
(D) s1 and s3
10. If 15 computers are to be connected using 8 port Ethernet switches, then the minimum numbers
of switches required are _____. Assume no separate uplink port is available
[Ans. *] Range: 3 to 3
PC1 PC2 PC3 PC4 PC5 PC6 PC7 PC8 PC9 PC10 PC12
1 2 3 4 5 6 7 8 1 2 3 4 5 6 7 P
8 port ethernet switch PC11 PC13
1 2 3 4 5 6 7 8
PC14 PC15
12. Consider ‘3’ concurrent process p1 , p2 , p3 access shared variable ‘D’ that has been to 100
P1 P2 P3
. . .
. . .
D = D + 20 D = D − 50 D = D + 10
. .
. .
Don’t Wait! Know Your GATE Rank with GATE Rank Predictor. Predict Now, http://bit.ly/grp2019
: 080-4061 1000, info@thegateacademy.com ©Copyright reserved. Web:www.thegateacademy.com
10
CS
With uniprocessor system, are running time shared system. If the minimum and maximum
values possible for ‘D’ is x and y respectively. After completion of ‘3’ processes, the value of
y − x =__________
[Ans. *]Range 70 to 70
15. Consider n unsorted arrays, n is odd. Each array is having n distinct elements A1 , A2 , … … An .
(There is no common element in 2 arrays) what is the worst case time complexity the median of
medians of A1 , … … An .
(A) 0(n logn )
(B) 0 (n2 logn)
(C) 0(n)
(D) 0(n2 )
[Ans. B]
A/q To Me for sorting we will require "n(logn)" time & we have "n" such arrays there so we will
require O(n2 (logn)) for the worst case.
Don’t Wait! Know Your GATE Rank with GATE Rank Predictor. Predict Now, http://bit.ly/grp2019
: 080-4061 1000, info@thegateacademy.com ©Copyright reserved. Web:www.thegateacademy.com
11
CS
17. L is regular grammar over ∑ = {a, b}. find which one is not regular
(A) L. LR = {xy |x ∈ L; y ∈ LR , LR is reversable of L}
(B) Suffix (L) = {y ∈ ∑∗ | ∃x∑∗ xy ∈ L}
(C) Prefix (L) = (y ∈ ∑∗ | ∃x∑∗ yx ∈ L
(D) {WW R |W ∈ L, W R is reverse of W}
[Ans. D]
18. Which of the following is not correct about B + Tree, which is used for creating as index of
relational database table?
(A) Key values in each node are kept in sorted order
(B) Leaf node pointer points to next node
(C) B + tree is height balanced tree
(D) Non-leaf have pointers to data records
[Ans. D]
20. What is the total number of different Hamiltonian cycles for the complete graph of n vertices?
[Ans. *]
(n − 1)!/2
Don’t Wait! Know Your GATE Rank with GATE Rank Predictor. Predict Now, http://bit.ly/grp2019
: 080-4061 1000, info@thegateacademy.com ©Copyright reserved. Web:www.thegateacademy.com
12
CS
x4 −81
22. limx→3 ax2 −5x−3
[Ans. *]
34 − 81 81 − 81 0
2
= = → indeterminant
2 × 3 − 5 × 3 − 3 18 − 15 − 3 0
L′ Hospital
4x 3
lim
x→3 4x − 5
4 × 33 108
⇒ =
4×3−5 7
23. Which of the following are used to send and retrieve emails respectively?
(A) SMTP and IMAP
(B) SMTP and POP3
(C) IMAP and POP3
(D) POP3 and SMTP
Don’t Wait! Know Your GATE Rank with GATE Rank Predictor. Predict Now, http://bit.ly/grp2019
: 080-4061 1000, info@thegateacademy.com ©Copyright reserved. Web:www.thegateacademy.com
13
CS
(P×R) (Q×R)
πx (σ(P.Y=R.Y ⋀ R.V=V2) ) ) − πx (σ(Q.Y=R.Y ⋀Q.T>2) ) )
How many tuples are returned?
[Ans. *]Range 1 to 1
27. Given that Roll-No in student is primary key in table performance the Roll-No & subject –
code combinely from primary key. Consider the query given to identify the no.of rows
retrieved after execution?
Student
Roll_No Student Name
1 Amit
2 Priya
3 Vineet
4 Rohan
5 Smita
Performance
Roll_No Subject_code Marks
1 A 86
1 B 95
1 C 90
Don’t Wait! Know Your GATE Rank with GATE Rank Predictor. Predict Now, http://bit.ly/grp2019
: 080-4061 1000, info@thegateacademy.com ©Copyright reserved. Web:www.thegateacademy.com
14
ME-
CS
2 A 89
2 C 92
3 C 80
SELECT s.student_name, sum(p.marks)
FROM student s, performance P
WHERE p.marks>84
GROUP BY s.student.name
[Ans. *]Range 2 to 2
29. Minimum number of 2-input NOR gates required to implement 4-variable function
expressed in sum of minterms as f = ∑m(0, 2, 5, 7, 8, 10, 13, 15). Assume that all the inputs
and their complements available.
[Ans. *]Range to 3 to 3
Don’t Wait! Know Your GATE Rank with GATE Rank Predictor. Predict Now, http://bit.ly/grp2019
: 080-4061 1000, info@thegateacademy.com ©Copyright reserved. Web:www.thegateacademy.com
15
ME-
CS
32. Consider ‘4’ processes p1 , p2 , p3 , p4 their arrival time and CPU burst time is given in the
table. SRTF scheduling algorthim is used. What is the value of ‘Z’ of average waiting time of
processes is 1ms.
Process Id Arrival Time Burst Time
p1 0 3
p2 1 1
p3 3 3
p4 4 ‘Z’
[Ans. *]Range 2 to 2
33. Consider Unix based file system (I-node), with 12 Direct addresses, one single indirection,
and one double indirection pointers, disk block size is 4kB and disk block addresses are 32
bits. Maximum file size is possible in this system ________GB
[Ans. *]Range 4 to 4
4kB
No of entries in block = 4B
= 1k
File size = 12 × 4kB + 1kB × 4kB + 1k × 1k × 4kB
= 48kB + 4MB + 4GB
= 4.004048 GB
Don’t Wait! Know Your GATE Rank with GATE Rank Predictor. Predict Now, http://bit.ly/grp2019
: 080-4061 1000, info@thegateacademy.com ©Copyright reserved. Web:www.thegateacademy.com
16
ME-
CS
[Ans. A]
Both the statements 1 & 2 are correct.
1. If every edge of an undirected graph has a unique weight, it will have a unique MST.
2. If every cut of a graph is connected with a unique minimum weight edge, the graph will
have a unique MST.
(This question is directly asked from class notes which I have mentioned as VVIMP
Question at the time of classes.)
Don’t Wait! Know Your GATE Rank with GATE Rank Predictor. Predict Now, http://bit.ly/grp2019
: 080-4061 1000, info@thegateacademy.com ©Copyright reserved. Web:www.thegateacademy.com
17
ME-
CS
IV) A binary search tree can be constructed from a max heap in O(n) time
Which of the above statements are true?
(A) I, III, IV
(B) I, II, IV
(C) I, II, III
(D) II, III, IV
40. An array of 25 distinct elements is sorted using Quicksort. Pivot is chosen randomly. What
is the probability of pivot element getting placed at worst possible location in the first
round of probability is ____________. (Round off to two decimal places).
43. A certain processor deploy a single level-cache, the cache block size is 8 words, word size
is 4 bytes, memory system uses 60mHz clock, to service a cache miss, the memory
controller first takes 1 clock cycle to accept starting address of the block, it then takes 3
Don’t Wait! Know Your GATE Rank with GATE Rank Predictor. Predict Now, http://bit.ly/grp2019
: 080-4061 1000, info@thegateacademy.com ©Copyright reserved. Web:www.thegateacademy.com
18
ME-
CS
cycles to fetch all the 8 words in the block & finally transmits the words of the requested
block at the rate of 1 word per cycle. The maximum bandwidth for the memory system
when the program on the processor issues a series of read operation is
_____________(106 Bytes/sec)
[Ans. *]Range 235.29 to 235.29
44. A network with three hosts M, N and P have IP address 194.X.10.2, 194.X.10.5 and
194.X.10.6 and their subnet mask is 255.255.255.252. Which of the following will be in a
same subnet?
(A) All three will be in same subnet
(B) M and N
(C) N and P
(D) All will be in different subnet
[Ans. C]
45. Consider the cache memory size of 16kb, and cache block size is 16 bytes. The processor
generates the physical address of 32 bits. Assume the cache is fully associative. What are
the TAG and index bits __________
(A) 28 and 4bits
(B) 28 and 0bits
(C) 24 and 4bits
(D) 24 and 0bits
[Ans. A]
Cache size=16kB, Block size=16B
PA=32 bits, fully Associative cache
PA = 32 bit
TAG WO
28 bit 4 bit
TAG = 28 bits
Index = (PA − TAG)bits
= 4 bits
1
46. ⃗ = 3 (−y 3 î + x 3 ĵ + z 3 k̂) & n̂ as the unit normal vector to surface of semi
Given vector u
sphere (x 2 + y 2 + z 2 = 1, z ≥ 0)
Don’t Wait! Know Your GATE Rank with GATE Rank Predictor. Predict Now, http://bit.ly/grp2019
: 080-4061 1000, info@thegateacademy.com ©Copyright reserved. Web:www.thegateacademy.com
19
ME-
CS
50. Consider the language: L = {a2+3k or b10+12k } for k ≥ 0. Which of the following is correct
for the length of string L to satisfy Pumping Lemma?
(A) 5
(B) 24
(C) 9
(D) 3
51. Consider the following processes using preemptive shortest remaining time first.
P1 P2 P3 P4
Arrival time 0 1 3 4
CPU time 3 1 3 Z
If the average waiting time is 1 ms then what is the value of Z?
[Ans. *]Range 3 to 3
Don’t Wait! Know Your GATE Rank with GATE Rank Predictor. Predict Now, http://bit.ly/grp2019
: 080-4061 1000, info@thegateacademy.com ©Copyright reserved. Web:www.thegateacademy.com
20
ME-
CS
Don’t Wait! Know Your GATE Rank with GATE Rank Predictor. Predict Now, http://bit.ly/grp2019
: 080-4061 1000, info@thegateacademy.com ©Copyright reserved. Web:www.thegateacademy.com
21