# (Paper) IIT Kanpur | M.E. Computer Science Question Paper

**IIT Kanpur | M.E. Computer Science Question Paper**

**Duration: **3 Hours Maximum Marks:150

**Read the following instructions carefully:**

1. This question paper contains all objective questions. Q.1 to Q.30 carry One mark each and
Q.31 to Q.80 carry Two marks each. Q.81 to Q.85 each contains part “a” and “b”. In these
questions, parts “a” as well as “b” carry Two marks each.

2. Answer all the questions.

3. Questions must be answered on special machine gradable Objective Response Sheet (ORS)
by darkening the appropriate bubble (marked A, B, C, D) against the question number on the
left hand side of the ORS, using HB pencil. Each question has only one correct answer. In case
you wish to change an answer, erase the old answer completely using a good soft eraser.

4. There will be NEGATIVE marking. In Q.1 to Q.30, 0.25 mark will be deducted for each
wrong answer and in Q.31 to Q.80, 0.5 mark will be deducted for each wrong answer. In Q.81
to Q.85, for the part “a”, 0.5 marks will be deducted for a wrong answer. Marks for correct
answers to part “b” of Q.81 to Q.85 will be given only if the answer to the corresponding part “a” is correct. HoWever there is no negative marking for part “b” of Q.81 to Q.85. More than

one answer Liubbled against a question will be deemed as an incorrect response.

5. Write your registration number, name and name of the Centre at the specified locations on
the right half of the ORS.

6. Using HB pencil, darken the appropriate bubble under each digit of your registration
number and the letters corresponding to your paper code.

7. Calculator is allowed in the examination hall.

8. Charts, graph sheets or tables are not allowed.

9. Use the blank pages given at the end of the question paper for rough work.

10. Please check all pages and report, if there is any discrepancy.

**Q.1 — Q.30 Carry One Mark Each**

1. A bag contains 10 blue marbles, 20 green marbles and 30 red marbles. A marble is drawn
from the bag, its colour recorded and it is put back in the bag. This process is repeated 3
times. The probability that no two of the marbles drawn have the same colour is

(A) 36

(B) 6

(C) 4

(D) 3

**2. If the trapezoidal method is used to evaluate the integral [x2dx, then the value obtained**

1 1 1

(A) is always >

(B) is always <

(C) is always =

(D) may be greater or lesser than

3. The determinant of the matrix givën.below is

0 1 0 2

—1 1 1 3

0 0 0 1

1 —2 0 1

(A) -1

(B) 0

(C) 1

(D)2

**4. Let L be a regular language and M be a context free language, both over the
alphabet . Let LCand MCdenote the complements of L and M respectively.
Which of the following statements about the language LC u MC is TRUE?**

(A) It is necessarily regular but not necessarily context free

(B) It is necessarily context free

(C) It is necessarily non-regular

(D) None of the above

**5. Which of the following statements is TRUE about the regular expression 01*0?**

(A) It represents a finite set of finite strings.

(B) It represents an infinite set of finite strings.

(C) It represents a finite set of infinite strings.

(D) It represents an infinite set of infinite strings.

**6. The language {oi 21 < n < 1061 is:**

(A) regular

(B) context free but not regular

(C) context free but its complement is not context free

(D) not context free

**7. Which of the following expressions is equivalent to (A $ B) $ C**

(A) (A+B+C)(A++)

(C) ABC+A(B$C)+B(A$C)

(B) (A+B+C)(A++C)

(D) None of the above

**8. Using Booth’s algorithm for multiplication, the multiplier — 57 will be recorded as**

(A) 0 —1 0 0 1 0 0 -1

(C) 0 -1 0 0 1 0 0 0

(B) 1 1 0 0 0 1 1 1

(D) 0 1 0 0 -1 0 0 1

**9. A dynamic RAM has a memory cycle time of 64 nsec. It has to be refreshed 100 times per
msec and each refresh takes 100 nsec. What percentage of the memory cycle time is used for
refreshing?**

(A) 10

(B) 6.4

(C) 1

(D)0.64

**10. A two-way switch has three terminals a, b and c. In ON position (logic value 1) a is
connected to b, and in OFF position, a is connected to c. two of these two way switches Si and
S2 are connected to a bulb as shown below.**

Which of the following expressions, if true, will always result in the lighting of the bulb?

(A) Si.S2

(B) Si+S2

(C) Si$S2

(D)Si$S2

**11. How many pulses are needed to change the contents of a 8 bit up-counter from 10101100**

to 00100111 (rightmost bit is the LSB)?

(A) 134

(B) 133

(C) 124

(D) 123

**12. The numbers 1, 2, n are inserted in a binary search tree in some order. In the resulting
tree, the right subtree of the root contains p nodes. The first number to be inserted in the tree
must be**

(A) p

(B) p + 1

(C) n - p

(D)n — p + 1

**13. A function f defined on stacks of integers satisfies the following properties. f(q5) = Oand f
(push(S,i)) = max(f (S),0)+ifor all stacks S and integers i.
If a stack S contains the integers 2, -3, 2, -1, 2 in order from bottom to top, what is f(s)?**

(A) 6

(B) 4

(C) 3

(D)2

**14. In a depth first traversal of a graph G with n vertices, k edges are marked as tree edges.
The number of connected components in G is**

(A) k

(B) k + 1

(C) n — k - 1

(D)n - k

**15. In the following table, the left column contains the names of standard graph algorithm,
and the right column contains the time complexities of the algorithms. Match each algorithm
with its time complexity.**

(1) Bellman Ford algorithm (A) 0 (mlog n)

(2) Kruskal’s algorithm (B) 0 (n3)

(3) Floyd-Warshall algorithm (C) 0 (nm)

(4) Topological Sorting (D) 0 (n + m)

(A)1-C2-A3-B4-D

(B)1-B2-D3-C4-A

(C)1-C2-D3-A4-B

(D)1-B2-A3-C4-D

**16. A hash table contains 10 buckets and uses linear probing to resolve collisions. The key
values are integers and the hash function used is key 0i’o 10. if the values 43, 165, 62, 123,
142 are inserted in the table, in what location would the key value 142 be inserted?**

(A) 2 (B) 3 (C) 4 (D)6

**17. A student wishes to create symbolic links in a computer system running Unix. Three text
files named “file 1”, “file 2”, and “file 3” exist in her current working directory and the student
has read and write permissions for all three files. Assume that file 1 contains information
about her hobbies, file 2 contains information about her friends and file 3 contains information
about her courses. The student executes the following sequence of commands from her
current working directory?**

In — s file 1 file 2

In — s file 2 file 3

Which of the following types of information would be lost from her file system

I. Hobbies

II. Friends

III. Courses

(A) land II only

(B) II and III only

(C) II only

(D)I and III only

**18. The shell command
find. —name passwd —print is executed in/etc directory of a computer system running Unix.
Which of the following shell commands will give the same information as the above command
when executed in the same directory?**

(A) Is passwd

(B) cat passwd

(C) grep name passwd

(D) grep print passwd

**19. A user level process in Unix traps the signal sent on a Ctrl-C input, and has a signal
handling routine that saves appropriate files before terminating the process. When a Ctrl-C
input is given to this process, what is the mode in which
the signal handling routine executes?**

(A) kernel mode

(B) superuser mode

(C) privileged mode

(D) user mode

**20. The Function Point (FP) calculated for a software project are often used to obtain an
estimate of Lines of Code (LOC) required for that project. Which of the following statements if
FALSE in this context.**

(A) The relationship between FP and LOC depends on the programming language used to
implement the software.

(B) LOC requirement for an assembly language implementation will be more for a given FP
value, than LOC for implementation in COBOL.

(C) On an average, one LOC of C++ provides approximately 1.6 times the functionality of a
single LOC of FORTRAN.

(D) FP and LOC are not related to each other.

**21. Consider the entities ‘hotel room’, and ‘person’ with a many to many relationship ‘lodging’
as shown below:
Hotel Room Person
If we wish to store information about the rent payment to be made by person(s) occupying
different hotel rooms, then this information should appear as an
attribute of**

(A) Person

(B) Hotel Room

(C) Lodging

(D)None of these

**22. A table has fields Fl, F2, F3, F4, F5 with the following functional dependencies**

Fl - F3 F2 - F4 (F1.F2) - F5

In terms of Normalization, this table is in

(A) 1 NF

(B) 2 NF

(C) 3 NF

(D)None of these

**23. A B-tree used as an index for a large database table has four levels including the root
node. If a new key is inserted in this index, then the maximum number of nodes that could be
newly created in the process are**

(A) 5

(B) 4

(C) 3

(D)2

**24. Amongst the ACID properties of a transaction, the ‘Durability’ property requires
that the changes made to the database by a successful transaction persist**

(A) except in case of an Operating System crash

(B) except in case of Disk crash

(C) except in case of a power failure

(D) always, even if there is a failure of any kind

**25. Consider the three commands:, PROMPT, HEAD and RCPT.
Which of the following options indicate a correct association of these commands with protocols
where these are used?**

(A) HTTP, SMTP, FTP

(B) FTP, HTTP, SMTP

(C) HTTP, FTP, SMTP

(D) SMTP, HTTP, FTP

**26. Trace-route reports a possible route that is taken by packets moving from some host A to
some other host B. which of the following options represents the technique used by traceroute
to identify these hosts?**

(A) By progressively querying routers about the next router on the path to B using ICMP
packets, starting with the first router.

(B) By requiring each router to append the address to the ICMP packet as it is forwarded to B.
The list of all routers en-route to B is returned by B in an ICMP reply packet.

(C) By ensuring that an ICMP reply packet is returned to A by each router en- route to B, in
the ascending order of their hop distance from A

(D) By locally computing the shortest path from A to B

**27. Which of the following statements is TRUE about CSMA/CD**

(A) IEEE 802.11 wireless LAN runs CSMA/CD protocol

(B) Ethernet is not based on CSMA/CD protocol

(C) CSMA/CD is not suitable for a high propagation delay network like statellite network.

(D) There is no contention in a CSMA/CD network

**28. Which of the following statements is FALSE regarding a bridge**

(A) Bridge is a layer 2 device

(B) Bridge reduces collision domain

(C) Bridge is used to connect two or more LAN segments

(D) Bridge reduces broadcast domain

**29. Count to infinity is a problem associated with**

(A) link state routing protocol

(B) distance vector routing protocol

(C) DNS while resolving host name

(D) TCP for congestion control

**30. A HTML form is to be designed to enable purchase of office stationery. Required items are
to be selected (checked). Credit card details are to be entered and then the submit button is
to be pressed. Which one of the following options would be appropriate for sending the data to
the server? Assume that security is handled in a way that is transparent to the form design.**

(A) only GET

(B) only POST

(C) either of GET or POST

(D) neither gET not POST

**Q.31 - Q.80 Carry Two Marks Each.**

**31. Let f be a function from a set A to a set B, g a function from B to C, and h a function from
A to C, such that h(a) = g(f (a))for all a E A. Which of the following statements is always true
for all such functions f and g?**

(A) g is onto h is onto

(B) h is onto f is onto

(C) h is onto g is onto

(D) h is onto f and g are onto

**32. Let A be a set with n elements. Let C be a collection of distinct subsets of A such that for
any two subsets S1 and S2 in C, either S1 S or 2 S1. What is the maximum cardinality of C?**

(A) n

(B) n+1

(C) 2fh+1

(D)n!

**33. An unbiased coin is tossed repeatedly until the outcome of two successive tosses is the
same. Assuming that the trials are independent, the expected number of
tosses is:**

(A) 3

(B) 4

(C) 5

(D)6

**34. Let n = p2q,where p and q are distinct prime numbers. How many numbers m satisfy 1 m
nand gcd(m,n) = 1? Note that gcd(m,n) is the greatest common divisor of m and n.**

(A) p(q—i)

(C) (p2 —i)(q—i)

**35. What is the value of [(x — r)3 (sin x) dx**

(A) -1 (B) 0

(B) pq

(D) p(p—i)(q—i)

(C) 1 (D)t

**36. Let P(x) and Q(x) be arbitrary predicates. Which of the following statements is always
TRUE?**

(A) ((vxP (x) v Q (x))) ((vx ( (x) v (vxQ (x)))

(B) (vx(P (x) Q(x))) ((vx(P (x) (vxQ(x)))

(C) (vx(P(x)) (vxQ(x))) ((vx(P(x) Q(x)))

(D) (vx(P(x))) (vxQ(x)))

**37. Consider the non-deterministic finite automation (NFA) shown in the figure.
State X is the starting state of the automaton. Let the language accepted by the NFA with Y as
the only accepting state be Li. Similarly, let the language accepted by the NFA with Z as the
only accepting state be L2. Which of the following statements about Li and L2 is TRUE?**

(A) Li = L2

(B) LicL2

(C) L2cLi

(D) None of the above

**38. Let P be a non-deterministic pushdown automaton (NPDA) with exactly one state, q, and
exactly one symbol, Z, in its stack alphabet. State q is both the starting as well as the
accepting state of the PDA. The stack is initialized with one Z before the start of the operation
of the PDA. Let the input alphabet of the PDA be . Let L(P) be the language accepted by the
PDA by reading a string and reaching its accepting state. Let N(P) be the language accepted
by the PDA by reading a string and emptying its stack.
Which of the following statements is TRUE?**

(A) L(P) is necessarily *but N(P) is not necessarily *

(B) N(P) is necessarily * but L(P) is not necessarily *

(C) Both L(P) and N(P) is necessarily E*

(D) Neither L(P) nor N(P) are necessarily *

**39. Consider the regular grammar:**

S - XaYa

X-Za

Z - S a B

Y — Wa

W - Sa

Where S is the starting symbol, the set of terminals is {al and the set of nonterminals
is {S,W,X,Y,Z}.

We wish to construct a deterministic finite automaton (DFA) to recognize the same language.

What is the minimum number of states required for the DFA?

(A) 2 (B) 3 (C) 4 (D)5

**40. A language L satisfies the Pumping Lemma for regular languages, and also the Pumping
Lemma for context free languages. Which of the following statements about L is TRUE?**

(A) L is necessarily a regular language

(B) L is necessarily a context free language, but not necessarily a regular language

(C) L is necessarily a non-regular language

(D) None of the above

**41. Given below is a program which when executed spawns two concurrent processes:
Semaphore X:=0;**

1* Process now forks into concurrent processes P1 & P2 *1

P1 : repeat forever P2 : repeat forever

V(X); P(X);

Compute; Compute;

P(X); V(X);

Consider the following statements about processes P1 and P2:

I: It is possible for process P1 to starve.

II. It is possible for process P2 to starve.

Which of the following holds?

(A) Both I and II are true

(B) I is true but II is false

(C) II is true but I is false

(D) Both I and II are false

**42. Two concurrent processes P1 and P2 use four shared resources Ri, R2, R3 and R4, as shown below.**

P1: P2:

Compute; Compute;

Use Ri; Use Ri;

Use R2; Use R2;

Use R3; Use R3;

Use R4; Use R4;

Both processes are started at the same time, and each resource an be accessed by only one
process at a time. The following scheduling constraints exist between the access of resources
by the processes:

P2 must complete use of Ri before P1 gets access to Ri.

P1 must complete use of R2 before P2 gets access to R2.

P2 must complete use of R3 before P1 gets access to R3.

P1 must complete use of R4 before P2 gets access to R4.

There are no other scheduling constraints between the processes. If only binary
semaphores are used to enforce the above scheduling constraints, what is the

minimum number of binary semaphores needed?

(A) 1

(B) 2

(C) 3

(D)4

**44. We have two designs Di and D2 for a synchronous pipeline processor. Di has 5 pipeline
stages with execution times of 3 nsec, 2 nsec, 4 nsec, 2 nsec and 3 nsec while the design D2
has 8 pipeline stages each with 2 nsec execution time. How much time can be saved using
design D2 over design Di for executing 100
instructions?**

(A) 214 nsec (B) 202 nsec (C) 86 nsec (D)-200 nsec

**45. A hardwired CPU uses 10 control signals Si to SiO in various time steps Ti to T5 to
implement 4 instructions ii to 14 as shown below.**

Ti T2 T3 T4 T5

Ii Si, S3,

S5

S2, S4,

S6

Si, S7 Sb S3, S8

1

2

Si, S3,

S5

S8, S9, Sb S5, S6,

S7

S6 Sb

1

3

Si, S3,

S5

S7, S8, Sb S2, S6,

S9

Sb Si, S3

1

4

Si, S3,

S5

S2, S6,

S7

S5, Sb S6, S9 SiO

Which of the following pairs of expressions represent the circuit for generating control signals
S5 and Sb respectively [(Ij+Ik)Tnindicates that the control signal should be generated in time
step Tnif the instruction being executed is If or 1k].

(A) S5 =Ti + 12 .T3&SiO = (Ii + 13) .T4+ (12 + 14) .T5

(B) S5 = Ti + (12 + 14) . T3 & Sb = (Ii + 13) . T4 + (12 + 14) . T5

(C) S5 =Ti + (12 + 14) .T3&SiO = (12 + 13 + 14) .T2 + (Ii + 13) .T4+ (12 + 14). T5

(D) S5 = Ti + (12 + 14) . T3 & Sb = (12 + 13) . T2 + 14. T3 +(Ii + 13) . T4 + (12 + 14) . T5

**46. A line L in a circuit is said to have a stuck at 0 fault if the lien permanently has a logic
value 0. Similarly a line L in a circuit is said to have a stuck at 1 fault if the line permanently
has a logic value 1. a circuit is said to have a multiple stuck at fault if one or more lines have
stuck at faults. The total number of distinct multiple stuck at faults possible in a circuit with N
lines is:**

(A) 3” (B) 3”’ — 1 (C) 2”’ — 1 (D) 2”’

(A) (1053.6)8

(B) (1053.2)8

(C) (1024.2)8

(D) None of these

**49. An instruction set of a processor has 125 signals which can be divided into 5 groups of
mutually exclusive signals as follows:**

Group 1: 20 signals, Group 2: 70 signals, Group 3: 2 signals, Group 4: 10 signals, Group 5:

23 signals.

How many bits of the control words can be saved by using vertical microprogramming over
horizontal microprogramming?

(A) 0

(B) 103

(C) 22

(D)55

**50. In a binary tree, for every node the difference between the number of nodes in the left
and right subtrees is at most 2. If the height of the tree is h > 0, then the minimum number
of nodes in the tree is:**

(A) T(n)=8(logn)

(C) T(n)=8(n)

(B) T(fl)r=8(fi)

(D) T(n) = 8(nlogn)

**52. Let G be a weighted undirected graph and e be an edge with maximum weight in G.
Suppose there is a minimum weight spanning tree in G containing the edge e. Which of the
following statements is always TRUE?**

(A) There exists a cutest in G having all edges of maximum weight

(B) There exits a cycle in G having all edges of maximum weight

(C) Edge e cannot be contained in a cycle

(D) All edges in G have the same weight

**53. The following C function takes two ASCII strings and determines whether one is an
anagram of the other. An anagram of a string s is a string obtained by permuting the letters in**

s.

mt anagram (char *a, char *b){

mt count [1281,1;

for (j = 0; j < 128; j++) count[j]=0;

j = 0;

while (a[j] && b[j]){

A;

B;

}

for (j = 0; 1 < 128; j++) if (count[j]) return 0;

return 1;

}

Choose the correct alternative for statements A and B.

(A) A: count [a[j]]++ and B: count[b[j]] (B

A: count [a[j]]++ and B: count[b[j]]++

(C) A: count[a[j++]]++ and B: count[b[j]] (D

A: count[a[j]]++ and B: count[b[j++]] 54

**54. The following C function takes a singly-linked list of integers as a parameter and
rearranges the elements of the list. The list is represented as pointer to a structure. The
function is called with the list containing the integers 1, 2, 3, 4, 5, 6, 7 in the given order.
What will be the contents of the list after the function completes execution?**

struct node (mt value; struct node * next;};

void rearrange (struct node *list) {

struct node *p, *q;

mt temp;

if (!list list – next) return;

p = list; q = list – next;

while (q) {

temp = p – value;

p – value = q – value;

q – value = temp;

p = q – next;

q = p? p – next; 0;

}

}

(A) 1, 2, 3, 4, 5, 6, 7

(B) 2, 1, 4, 3, 6, 5, 7

(C) 1, 3, 2, 5, 4, 7, 6

(D) 2, 3, 4, 5, 6, 7, 1

**55. A binary search tree contains the numbers 1, 2, 3, 4, 5, 6, 7, 8. When the tree is
traversed in pre-order and the values in each node printed out, the sequence of values
obtained is 5, 3, 1, 2, 4, 6, 8, 7. If the tree is traversed in post-order, the
sequence obtained would be**

(A) 8, 7, 6, 5, 4, 3, 2, 1

(B) 1, 2, 3, 4, 8, 7, 6, 5

(C) 2, 1, 4, 3, 6, 7, 8, 5

(D) 2, 1, 4, 3, 7, 8, 6, 5

**56. Let G be a directed graph whose vertex set is the set of numbers from 1 to 100. There is
an edge from a vertex i to a vertex j iff either j = i + 1 or j = 3i. The minimum number of
edges in a path in G from vertex 1 to vertex 100 is:**

(A) 4

(B) 7

(C) 23

(D)99

**57. What is the output printed by the following program?**

# include

mt f(int n, mt k) {

if (n = = 0) return 0;

else if (n°1o2) return f(n/2, 2*k) + k;

else return f(n/2, 2*k) — k;

mt main () {

printf(”°Iod”,f(20,1));

return 0;

(A) 5

(B) 8

(C) 9

(D)20

**58. Let a be an array containing n integers in increasing order. The following algorithm
determines whether there are two distinct numbers in the array whose difference is a specified**

number S > 0.

= 0; j =1;

while (j < n) {

if (E) j++;

else if (a[j] — a ==S) break;

else i++;

}

if (j < n) printf(”yes”) else printf (“no”);

Choose the correct expression for E.

(A) a[j] — a > S

(B) a[j] — a < S

(C) a — a[J] < S

(D) a — a[J] > S

**59. Let a and b be two sorted arrays containing n integers each, in non-decreasing order. Let
c be a sorted array containing 2n integers obtained by merging the two arrays a and b.
assuming the arrays are indexed starting from 0, consider the following four statements.**

I. a b c[2i] a

II. a b c[2i] b

III. a b c[2i] a

IV. a b c[2i] b

Which of the following is TRUE?

(A) only I and II

(B) only I and IV

(C) only II and III

(D) only III and IV

**60. We wish to schedule three processes P1, P2 and P3 on a uniprocessor system. The
priorities, CPU time requirements and arrival times of the processes are as shown below.
We have a choice of preemptive or non-preemptive scheduling. In preemptive scheduling, a
late-arriving higher priority process can preempt a currently running process with lower
priority. In non-preemptive scheduling, a late arriving higher priority process must wait for the
currently executing process to complete before it can be scheduled on the processor.
What are the turnaround times (time from arrival till completion) of P2 using preemptive and
non-preemptive scheduling respectively?**

Process Priority

CPU time

required

Arival time (hh:mm:ss)

P1

10

(highest)

20 sec 00:00:05

P2 9 10 sec 00:00:03

P3 8 (lowest) 15 sec 00:00:00

(A) 30 sec, 30 sec

(B) 30 sec, 10 sec

(C) 42 sec, 42 sec

(D) 30 sec, 42 sec

**61. Consider a 2-way set associative cache memory with 4 sets and total 8 cache blocks (0-7)
and a main memory with 128 blocks (0-127). What memory blocks will be present in the
cache after the following sequence of memory block references if LRU policy is used for cache
block replacement? Assuming that initially the cache did not have any memory block from the
current job?**

(A)03571655

(B)035791655

(C)05791655

(D)35791655

**62. Two shared resources R1 and R2are used by processes F and P2. Each process has a
certain priority for accessing each resource. Let denote the priority of P,for accessing R. A
process P,can snatch a resource Rkfrom process Pif T,kis greater than TJk.
Given the following:**

I. i

iii.

Which of the following conditions ensures that F and P2 can never deadlock?

(A) I and IV

(B) II and III

(C) I and II

(D) None of the above

**63. In a computer system, four files of size 11050 bytes, 4990 bytes, 5170 bytes and
12640 bytes need to be stored. For storing these files on disk, we can use either
100 byte disk blocks or 200 byte disk blocks (but can’t mix block sizes). For each block used
to store a file, 4 bytes of bookkeeping information also needs to be stored on the disk. Thus,
the total space used to store a file is the sum of the space taken to store the file and the space
taken to store the bookkeeping information for the blocks allocated for storing the file. A disk
block can store either bookkeeping information for a file or data from a file, but not both.
What is the total space required for storing the files using 100 byte disk blocks
and 200 byte disk blocks respectively?**

(A) 35400 and 35800 bytes

(B) 35800 and 35400 bytes

(C) 35600 and 35400 bytes

(D) 35400 and 35600 bytes

**64. The availability of a complex software is 90°h. Its Mean Time Between Failure (MTBF) is
200 days. Because of the critical nature of the usage, the organization deploying the software
further enhanced it to obtain an availability of 95%. In the process, the Mean Time To Repair
(MTTR) increased by 5 days.
What is the MTBF of the enhanced software?**

(A) 205 days

(B) 300 days

(C) 500 days

(D)700 days

**66. In a data flow diagram, the segment shown below is identified as having transaction flow
characteristics, with p2 identified as the transaction center.
A first level architectural design of this segment will result in a set of process modules with an
associated invocation sequence. The most appropriate architecture is:**

(A) p1 invokes p2, p2 invokes either p3, or p4, or p5

(B) p2 invokes p1, and then invokes p3, or p4 , or p5

(C) A new module Tc is defined to control the transaction flow. This module Tc fist invokes p1
and then invokes p2. p2 in turn invokes p3, or p4, or p5.

(D) A new module Tc is defined to control the transaction flow. This module Tc invokes p2. p2
invokes p1, and then invokes p3, or p4, or p5.

**67. A company maintains records of sales made by its salespersons and pays them
commission based on each individual’s total sales made in a year. This data is maintained in a
table with following schema:**

salesinfo = (salespersonid, totalsales, commission)

In a certain year, due to better business results, the company decides to further reward its

salespersons by enhancing the commission paid to them as per the following formula.

If commission < = 50000, enhance it by 2°h

If 50000 < commission < = 100000, enhance it by 4°h

If commission > 100000, enhance it by 6°h

The IT staff has written three different SQL scripts to calculate enhancement for

each slab, each of these scripts is to run as a separate transaction as follows:

Ti Update salesinfo

Set commission = commission * 1.02

Where commission < = 50000;

T2 Update salesinfo

Set commission = commission * 1.04

Where commission > 50000 and commission is <= 100000;

T3 Update salesinfo

Set commission = commission * 1.06

Where commission > 100000;

Which of the following options of running these transactions will update the

commission of all salespersons correctly?

(A) Execute Ti followed by T2 followed by T3

(B) Execute T2, followed by T3; Ti running concurrently throughout

(C) Execute T3 followed by T2; Ti running concurrently throughout

(D) Execute T3 followed by T2 followed by Ti

**68. A table ‘student’ with schema (roll, name, hostel, marks) and another table ‘hobby’ with
schema (roll, hobbyname) contains records as shown below.
The following SQL query is executed on the above tables:**

select hostel

from student natural join hobby

where marks > = 75 and roll between 2000 and 3000;

Relations S and H with the same schema as those of these two tables respectively contain the

same information as tuples. A new relation S’ is obtained by the following relational algebra

operation:

S = ‘1hose/ ((Js.ro//_H.ro// (marks>75 and ro//>2000 and ro//<3000 (s)) X (H))

The difference between the number of rows output by the SQL statement and the

number of tuples in S’ is:

(A) 6

(B) 4

(C) 2

(D)O

Table student Table hobby

Roll Name Hoste

l

Mark

s

Roll Hobbyname

179

8

Manoj Rathod 7 95 179

8

Chess

215

4

Soumic Banerjee 5 68 179

8

Music

236

9

Gumma Reddy 7 86 215

4

Music

258

1

Pradeep Pendse 6 92 236

9

Swimming

264

3

Suhas Kulkarni 5 78 258

1

Cricket

271

1

Nitin Kadam 8 72 264

3

Chess

287

2

Kiran Vora 5 92 264

3

Hockey

292

6

Manoj Kunkalikar 5 94 271

1

volleyball

295

9

Hemant

Karkhanis

7 88 287

2

Football

312

5

Rajesh Doshi 5 82 292

6

Cricket

295

9

Photography

312

5

Music

312

5

Chess

**69. In an inventory management system implemented at a trading corporation, there are
several tables designed to hold all the information. Amongst these, the following two tables
hold information on which items are supplied by which suppliers, and which warehouse keeps
which items along with the stock-level of these items.**

Supply = (supplierid, itemcode)

Inventory = (itemcode, warehouse, stocklevel)

For a specific information required by the management, following SQL query has

been written.

Select distinct STMP supplierid

From supply as STMP

Where not unique (Select ITMP.supplierid

From Inventory, Supply as ITMP

Where STMP.supplierid = ITMP.supplierid

And ITMP. itemcode = Inventory. itemcode

And Inventory.warehouse = ‘Nagpur’);

For the warehouse at Nagpur, this query will find all suppliers who

(A) do not supply any item

(B) supply exactly one item

(C) supply one or more items

(D) supply two or more items

**70. In a schema with attributes A, B, C, D and E following set of functional
dependencies are given.**

A-B

A-C

CD-E

B-D

E-A

Which of the following functional dependencies is NOT implied by the above set?

(A) CD – AC

(B) BD – CD

(C) BC – CD

(D)AC – BC

**71. A network with CSMA/CD protocol in the MAC layer is running at 1 Gbps over a 1 km cable
with no repeaters. The signal speed in the cable is 2×108m/sec. The minimum frame size for
this network should be**

(A) 10000 bits

(B) 10000 bytes

(C) 5000 bits

(D)5000 bytes

**72. A channel has a bit rate of 4 kbps and one-way propagation delay of 20 ms. The channel
uses stop and wait protocol. The transmission time of the acknowledgement frame is
negligible. To get a channel efficiency of at least 50°h, the minimum frame size should be**

(A) 80 bytes

(B) 80 bits

(C) 160 bytes

(D) 160 bits

**73. On a TCP connection, current congestion window size is Congestion Window = 4 KB. The
window size advertised by the received is Advertise Window = 6 KB. The last byte sent by the
sender is LastByteSent = 10240 and the last byte acknowledged by the receiver is
LastByteAcked = 8192. The current window size at the sender is:**

(A) 2048 bytes

(B) 4096 bytes

(C) 6144 bytes

(D)8192 bytes

**74. In a communication network, a packet of length L bits takes link Li with a probability of Pi
or link L2 with a probability of P2. Link Li and L2 have bit error probability of b1 and b2
respectively. The probability that the packet will be received without error via either Li or L2
is:**

(A) (i_b1)Lp1+(i_b2)Lp2 (B) [i_(b1+b2)P1P2

(C) (1—b1 )L (1 — b2 )L p1p2 (D) i — (bi’-p, + b21- p)

**75. In a TDM medium access control bus LAN, each station is assigned one time slot per cycle
for transmission. Assume that the length of each time slot is the time to transmit 100 bits plus
the end-to-end propagation delay. Assume a propagation speed of 2xiO8m/sec. The length of
the LAN is 1 km with a bandwidth of 10 Mbps. The maximum number of stations that can be
allowed in the LAN so that the throughput of each station can be Mbps is:**

(A) 3

(B) 5

(C) 10

(D)20

**76. A company has a class C network address of 204.204.204.0. It wishes to have three
subnets, one with 100 hosts and two with 50 hosts each. Which one of the following options
represents a feasible set of subnet address/subnet mask pairs?**

(A) 204.204.204.128/255.255.255.192

204.204.204.0/255.255.255.128

204.204.204.64/255.255.255.128

(B) 204.204.204.0/255.255.255.192

204.204.204.192/255.255.255.128

204.204.204.64/255.255.255.128

(C) 204.204.204.128/255.255.255.128

204.204.204.192/255.255.255.192

204.204.204.224/255.255.255.192

(D) 204.204.204.128/255.255.255.128

204.204.204.64/255.255.255.192

204.204.204.0/255.255.255.192

**77. Assume that “hostl.mydomain.dom” has an IP address of 145.128.16.8. Which of the
following options would be most appropriate as a subsequence of **steps in performing the
reverse lookup of 145.128.16.8? In the following options “NS” is an abbreviation of“nameserver”?

(A) Query a NS for the root domain and then NS for the “dom” domains

(B) Directly query a NS for “dom” and then a NS for “mydomain.dom” domains

(C) Query a NS for in-addr.arpa and then a NS for 128.145.in-addr.arpa domains

(D) Directly query a NS for 145.in-addr.arpa and then a NS for 128.145.in- addr.arpa
domains.

**78. Consider the following message M = 1010001101. The cyclic redundancy check (CRC) for
this message using the divisor polynomial x5 + x4 + x2 + 1 is:**

(A) 01110

(B) 01011

(C) 10101

(D)10110

**79. Suppose that two parties A and B wish to setup a common secret key (D-H key) between
themselves using the Diffie-Hellman key exchange technique. They agree on 7 as the modulus
and 3 as the primitive root. Party A chooses 2 and party B chooses 5 as their respective
secrets. Their D-H key is:**

(A) 3

(B) 4

(C) 5

(D)6

**80. Given below is an excerpt of an xml specification.**

10237623786

0024154807

Given below are several possible excerpts from “libratry.dtd”. For which excerpt would the
above specification be valid?

(A)

(B)

(C)

(D)

**Linked Answer Questions: Q.81a to Q85b Carry Two Marks Each.
Statement for Linked Answer Questions 81a and 81b:**

A disk has 8 equidistant tracks. The diameters of the innermost and outermost tracks are 1 cm and 8 cm respectively. The innermost track has a storage capacity of 10 MB.

**81. (A) What is the total amount of data that can be stored on the disk if it is used with a
drive that rotates it with**

(i) Constant Linear Velocity

(ii) Constant Angular Velocity

(A) (i) 80 MB (ii) 2040 MB (B) (i) 2040 MB (ii) 80 MB

(C) (i) 80 MB (ii) 360 MB (D) (i) 360 MB (ii) 80 MB

**81. (B)** If the disk has 20 sectors per track and is currently at the end of the 5th sector of the
inner most track and the head can move at a speed of 10 meters/sec and it is rotating at
constant angular velocity of 6000 RPM, how much time will it take to read 1 MB contiguous
data starting from the sector 4 of the outer most track?

(A) 13.5 ms

(B) 10 ms

(C) 9.5 ms

(D)20 ms

**Statement for Linked Answer Questions 82a and 82b:**

A database table Ti has 2000 records and occupies 80 disk blocks. Another table T2 has 400
records and occupies 20 disk blocks. These two tables have to be joined as per a specified join
condition that needs to be evaluated for every pair of records from these two tables. The
memory buffer space available can hold exactly one block of records for Ti and one block of
records for T2 simultaneously at any point in time. No index is available on either table.

**82. (A) If Nested loop join algorithm is employed to perform the join, with the most
appropriate choice of table to be used in outer loop, the number of block accesses required for
reading the data are:**

(A) 800000

(B) 40080

(C) 32020

(D) 100

**82. (B)** If, instead of Nested loop join, Block nested loop join is used, again with the most
appropriate choice of table in the outer loop, the reduction in number of block accesses
required for reading the data will be:

(A) 0

(B) 30400

(C) 38400

(D)798400

**Statement for Linked Answer Questions 83a and 83b:**

Consider the context-free grammar

E -E+E

E _(E*E)

E - Id

Where E is the starting symbol, the set of terminals is {id,(,+,),*, and the set of
non-terminals is {E}.

**83. (A) Which of the following terminal strings has more than one parse tree when parsed
according to the above grammar?**

(A) id + id + id + id

(B) id + (id* (id * id))

(C) (id * (id*id)) + id

(D) ((id * id + id) * id)

**83. (B) **For the terminal string with more than one parse tree obtained as solution to Question
83a, how many parse trees are possible?

(A) 5

(B) 4

(C) 3

(D)2

**Statement for Linked Answer Questions 84a and 84b:**

A sink in a directed graph is a vertex isuch that there is an edge from every vertex j Ito land
there is no edge from Ito any other vertex. A directed graph G with n vertices is represented
by its adjacency matrix a, where A[ijjl = 1 if there is an edge directed from vertex I tojand 0
otherwise. The following algorithm determines whether there is a sink in the graph G.

I = 0;

do {

j=i+1;

while((j

if (j

} while (j

flag =1;

for(j = 0 ;j < n ;j + +)

if (j!=i)&&E3) flag =0;

if(flag) printf(”Sink exists”) else printf(”Sink does not exist”);

**84. (A) Choose the correct expressions for E1 and E2**

(A) E1 : A [1111 and E2 : =

(B) (!A[ijjl& &!A[jjij)

(C) E1 : !A[ijjl and E2 :1 =

(D) (A[ijfj !A[jji1)

**84. (B) **Choose the correct expression for E3

(A) (A[ijjl& &!A[f Ill)

(C) (!A[ijfj !A[jji1)

(B) E1:!A[ijjl and E2:i=j+1;

(D) E1 :A[ijjl and E2 :i=j+1;

**Statement for Linked Answer Questions 85a and 85b:**

Consider a simple graph with unit edge costs. Each node in the graph represents a router.
Each node maintains a routing table indicating the next hop router to be used to relay a
packet to its destination and the cost of the path to the destination through that router.
Initially, the routing table is empty. The routing table is synchronously updated as follows. In
each updation interval, three tasks are performed.

(i) A node determines whether its neighbours in the graph are accessible. If so, it sets the
tentative cost to each accessible neighbour as 1. Otherwise, the cost is set to .

(ii) From each accessible neighbour, it gets the costs to relay to other nodes via that
neighbour (as the next hop)

(iii) Each node updates its routing table based on the information received in the previous two
steps by choosing the minimum cost.

**85. (A) For the graph given above, possible routing tables for various nodes after they have**

stabilized, are shown in the following options. Identify the correct table?

(A) Table for node A (B) Table for node C

A- AA1

BB1 BB1

Ccl C- -

DB3 DD1

EC3 EEl

FC4 FE3

(C) Table for node B (D) Table for node D

A A 1 A B3

B - - B B1

C C 1 C C1

D Dl D

E C 2 E E1

F D 2 F Fj]

**85. (B)** Continuing from the earlier problem, suppose at some time t, when the costs have
stabilized, node A goes down. The cost from node F to node A at time (t+100)is:

(A) > 100 but finite

(B)

(C) 3

(D) >3 and 100