Question : 1
The cost function for a product in a firm is given by \(5q^2\) , where \(q\) is the amount of production. The firm can sell the product at a market price of ₹ 50 per unit. The number of units to be produced by the firm such that the profit is maximized is
5
10
15
25
Correct Answer : A
Question Type : MCQ
Max Marks : 1
Negative Marks : 0.33
Question : 2
Choose the most appropriate alternative from the options given below to complete the following sentence:
Despite several ––––––––– the mission succeeded in its attempt to resolve the conflict.
attempts
setbacks
meetings
delegations
Correct Answer : B
Question Type : MCQ
Max Marks : 1
Negative Marks : 0.33
Question : 3
Which one of the following options is the closest in meaning to the word given below?
Mitigate
Diminish
Divulge
Dedicate
Denote
Correct Answer : A
Question Type : MCQ
Max Marks : 1
Negative Marks : 0.33
Question : 4
Choose the grammatically INCORRECT sentence:
They gave us the money back less the service charges of Three Hundred rupees.
This country’s expenditure is not less than that of Bangladesh.
The committee initially asked for a funding of Fifty Lakh rupees, but later settled for a lesser sum.
This country’s expenditure on educational reforms is very less.
Correct Answer : D
Question Type : MCQ
Max Marks : 1
Negative Marks : 0.33
Question : 5
Choose the most appropriate alternative from the options given below to complete the following sentence:
Suresh’s dog is the one ––––––––– was hurt in the stampede.
that
which
who
whom
Correct Answer : MTA
Question Type : MCQ
Max Marks : 1
Negative Marks : 0.33
Question : 6
Wanted Temporary, Part-time persons for the post of Field Interviewer to conduct personal interviews to collect and collate economic data. Requirements: High School-pass, must be available for Day, Evening and Saturday work. Transportation paid, expenses reimbursed.
Which one of the following is the best inference from the above advertisement?
Gender-discriminatory
Xenophobic
Not designed to make the post attractive
Not gender-discriminatory
Correct Answer : D
Question Type : MCQ
Max Marks : 2
Negative Marks : 0.67
Question : 7
A political party orders an arch for the entrance to the ground in which the annual convention is being held. The profile of the arch follows the equation \(y=2x-0.1x^{2}\) where \(y\) is the height of the arch in meters. The maximum possible height of the arch is
8 meters
10 meters
12 meters
14 meters
Correct Answer : B
Question Type : MCQ
Max Marks : 2
Negative Marks : 0.67
Question : 8
An automobile plant contracted to buy shock absorbers from two suppliers X and Y. X supplies 60% and Y supplies 40% of the shock absorbers. All shock absorbers are subjected to a quality test. The ones that pass the quality test are considered reliable. Of X’s shock absorbers, 96% are reliable. Of Y’s shock absorbers, 72% are reliable.
The probability that a randomly chosen shock absorber, which is found to be reliable, is made by Y is
0.288
0.334
0.667
0.720
Correct Answer : B
Question Type : MCQ
Max Marks : 2
Negative Marks : 0.67
Question : 9
Which of the following assertions are CORRECT?
P: Adding 7 to each entry in a list adds 7 to the mean of the list
Q: Adding 7 to each entry in a list adds 7 to the standard deviation of the list
R: Doubling each entry in a list doubles the mean of the list
S: Doubling each entry in a list leaves the standard deviation of the list unchanged
P, Q
Q, R
P, R
R, S
Correct Answer : C
Question Type : MCQ
Max Marks : 2
Negative Marks : 0.67
Question : 10
Given the sequence of terms, AD CG FK JP, the next term is
OV
OW
PV
PW
Correct Answer : A
Question Type : MCQ
Max Marks : 2
Negative Marks : 0.67
Question : 11
Consider the following logical inferences.
I1: If it rains then the cricket match will not be played.
The cricket match was played.
Inference: There was no rain.
I2: If it rains then the cricket match will not be played.
It did not rain.
Inference: The cricket match was played.
Which of the following is TRUE?
Both I1 and I2 are correct inferences
I1 is correct but I2 is not a correct inference
I1 is not correct but I2 is a correct inference
Both I1 and I2 are not correct inferences
Correct Answer : B
Question Type : MCQ
Max Marks : 1
Negative Marks : 0.33
Question : 12
Which of the following is TRUE?
Every relation in 3NF is also in BCNF
A relation R is in 3NF if every non-prime attribute of R is fully functionally dependent on every key of R
Every relation in BCNF is also in 3NF
No relation can be in both BCNF and 3NF
Correct Answer : C
Question Type : MCQ
Max Marks : 1
Negative Marks : 0.33
Question : 13
What will be the output of the following C program segment?
char inChar = 'A'; switch ( inChar ) { case 'A' : printf ("Choice A \ n"); case 'B' : case 'C' : printf ("Choice B"); case 'D' : case 'E' : default : printf ("No Choice"); }
No Choice
Choice A
Choice A
Choice B No Choice
Program gives no output as it is erroneous
Correct Answer : MTA
Question Type : MCQ
Max Marks : 1
Negative Marks : 0.33
Question : 14
Assuming P ≠ NP, which of the following is TRUE?
NP-complete = NP
NP-complete ∩ P = \(\phi\)
NP-hard = NP
P = NP-complete
Correct Answer : B
Question Type : MCQ
Max Marks : 1
Negative Marks : 0.33
Question : 15
The worst case running time to search for an element in a balanced binary search tree with \(n2^n\) elements is
\(Θ (n \ log \ n)\)
\(Θ (n2^n)\)
\(Θ (n)\)
\(Θ (log \ n)\)
Correct Answer : C
Question Type : MCQ
Max Marks : 1
Negative Marks : 0.33
Question : 16
The truth table
\({\begin{array}{|c|c|c|}\hline \textbf{X}& \textbf{Y}& \textbf{(X,Y)} \\\hline 0& 0& 0 \\ \hline 0& 1&0\\ \hline 1& 0& 1 \\\hline 1& 1& 1 \\\hline \end{array}}\)
represents the Boolean function
X
X + Y
X \(\oplus\) Y
Y
Correct Answer : A
Question Type : MCQ
Max Marks : 1
Negative Marks : 0.33
Question : 17
The decimal value 0.5 in IEEE single precision floating point representation has
fraction bits of 000…000 and exponent value of 0
fraction bits of 000…000 and exponent value of −1
fraction bits of 100…000 and exponent value of 0
no exact representation
Correct Answer : B
Question Type : MCQ
Max Marks : 1
Negative Marks : 0.33
Question : 18
A process executes the code
fork();
fork();
fork();
The total number of child processes created is
3
4
7
8
Correct Answer : C
Question Type : MCQ
Max Marks : 1
Negative Marks : 0.33
Question : 19
Consider the function \(f(x) = sin(x)\) in the interval \(x \in [π/4, 7π/4]\). The number and location(s) of the local minima of this function are
One, at π/2
One, at 3π/2
Two, at π/2 and 3π/2
Two, at π/4 and 3π/2
Correct Answer : D
Question Type : MCQ
Max Marks : 1
Negative Marks : 0.33
Question : 20
The protocol data unit (PDU) for the application layer in the Internet stack is
Segment
Datagram
Message
Frame
Correct Answer : C
Question Type : MCQ
Max Marks : 1
Negative Marks : 0.33
Question : 21
Let A be the 2 × 2 matrix with elements a11 = a12 = a21 = +1 and a22 = −1. Then the eigenvalues of the matrix A19 are
1024 and −1024
1024√2 and −1024√2
4√2 and −4√2
512√2 and −512√2
Correct Answer : D
Question Type : MCQ
Max Marks : 1
Negative Marks : 0.33
Question : 22
What is the complement of the language accepted by the NFA shown below? Assume \(\sum = \{a\}\) and \(\varepsilon\) is the empty string
\(\phi\)
\(\{\varepsilon \}\)
\(a^*\)
\(\{a, \varepsilon \}\)
Correct Answer : B
Question Type : MCQ
Max Marks : 1
Negative Marks : 0.33
Question : 23
What is the correct translation of the following statement into mathematical logic?
“Some real numbers are rational”
\(\exists x (\text{real}(x) \lor \text{rational}(x))\)
\(\forall x (\text{real}(x) \to \text{rational}(x))\)
\(\exists x (\text{real}(x) \wedge \text{rational}(x))\)
\(\exists x (\text{rational}(x) \to \text{real}(x))\)
Correct Answer : C
Question Type : MCQ
Max Marks : 1
Negative Marks : 0.33
Question : 24
Given the basic ER and relational models, which of the following is INCORRECT?
An attribute of an entity can have more than one value
An attribute of an entity can be composite
In a row of a relational table, an attribute can have more than one value
In a row of a relational table, an attribute can have exactly one value or a NULL value
Correct Answer : C
Question Type : MCQ
Max Marks : 1
Negative Marks : 0.33
Question : 25
Which of the following statements are TRUE about an SQL query?
P : An SQL query can contain a HAVING clause even if it does not have a GROUP BY clause
Q: An SQL query can contain a HAVING clause only if it has a GROUP BY clause
R : All attributes used in the GROUP BY clause must appear in the SELECT clause
S : Not all attributes used in the GROUP BY clause need to appear in the SELECT clause
P and R
P and S
Q and R
Q and S
Correct Answer : C
Question Type : MCQ
Max Marks : 1
Negative Marks : 0.33
Question : 26
The recurrence relation capturing the optimal execution time of the Towers of Hanoi problem with \(n\) discs is
\(T(n) = 2T(n − 2) + 2\)
\(T(n) = 2T(n − 1) + n\)
\(T(n) = 2T(n/2) + 1\)
\(T(n) = 2T(n − 1) + 1\)
Correct Answer : D
Question Type : MCQ
Max Marks : 1
Negative Marks : 0.33
Question : 27
Let G be a simple undirected planar graph on 10 vertices with 15 edges. If G is a connected graph, then the number of bounded faces in any embedding of G on the plane is equal to
3
4
5
6
Correct Answer : D
Question Type : MCQ
Max Marks : 1
Negative Marks : 0.33
Question : 28
Let \(W(n) \) and \(A(n)\) denote respectively, the worst case and average case running time of an algorithm executed on an input of size \(n\). Which of the following is ALWAYS TRUE?
\( A(n) = Ω (W(n))\)
\(A(n) = Θ (W(n))\)
\(A(n) = O (W(n))\)
\(A(n) = o (W(n))\)
Correct Answer : C
Question Type : MCQ
Max Marks : 1
Negative Marks : 0.33
Question : 29
The amount of ROM needed to implement a 4 bit multiplier is
64 bits
128 bits
1 Kbits
2 Kbits
Correct Answer : D
Question Type : MCQ
Max Marks : 1
Negative Marks : 0.33
Question : 30
Register renaming is done in pipelined processors
as an alternative to register allocation at compile time
for efficient access to function parameters and local variables
to handle certain kinds of hazards
as part of address translation
Correct Answer : C
Question Type : MCQ
Max Marks : 1
Negative Marks : 0.33
Question : 31
Consider a random variable \(X\) that takes values +1 and −1 with probability 0.5 each. The values of the cumulative distribution function \(F(x)\) at \(x\) = −1 and +1 are
0 and 0.5
0 and 1
0.5 and 1
0.25 and 0.75
Correct Answer : C
Question Type : MCQ
Max Marks : 1
Negative Marks : 0.33
Question : 32
Which of the following transport layer protocols is used to support electronic mail?
SMTP
IP
TCP
UDP
Correct Answer : C
Question Type : MCQ
Max Marks : 1
Negative Marks : 0.33
Question : 33
In the IPv4 addressing format, the number of networks allowed under Class C addresses is
214
27
221
224
Correct Answer : C
Question Type : MCQ
Max Marks : 1
Negative Marks : 0.33
Question : 34
Which of the following problems are decidable?
1) Does a given program ever produce an output?
2) If \(L\) is a context-free language, then, is \(\overline L\) also context-free?
3) If \(L\) is a regular language, then, is \(\overline L\) also regular?
4) If \(L\) is a recursive language, then, is \(\overline L\) also recursive?
1, 2, 3, 4
1, 2
2, 3, 4
3, 4
Correct Answer : D
Question Type : MCQ
Max Marks : 1
Negative Marks : 0.33
Question : 35
Given the language \(L = \{ab, aa, baa\}\), which of the following strings are in \(L^*\)?
\(1) abaabaaabaa \\ 2) aaaabaaaa \\ 3) baaaaabaaaab \\ 4) baaaaabaa\)
1, 2 and 3
2, 3 and 4
1, 2 and 4
1, 3 and 4
Correct Answer : C
Question Type : MCQ
Max Marks : 1
Negative Marks : 0.33
Question : 36
Which of the following graphs is isomorphic to
Correct Answer : B
Question Type : MCQ
Max Marks : 2
Negative Marks : 0.67
Question : 37
Consider the following transactions with data items P and Q initialized to zero:
T1 :read (P);
read (Q);
if P = 0 then Q := Q + 1 ;
write (Q).
T2 : read (Q);
read (P);
if Q = 0 then P := P + 1 ;
write (P).
Any non-serial interleaving of T1 and T2 for concurrent execution leads to
a serializable schedule
a schedule that is not conflict serializable
a conflict serializable schedule
a schedule for which a precedence graph cannot be drawn
Correct Answer : B
Question Type : MCQ
Max Marks : 2
Negative Marks : 0.67
Question : 38
The bisection method is applied to compute a zero of the function \(f(x) =x ^{4} – x ^{3} – x ^{2} – 4\) in the interval [1,9]. The method converges to a solution after ––––– iterations.
1
3
5
7
Correct Answer : B
Question Type : MCQ
Max Marks : 2
Negative Marks : 0.67
Question : 39
Let \(G\) be a weighted graph with edge weights greater than one and \(G'\) be the graph constructed by squaring the weights of edges in \(G\). Let \(T\) and \(T'\) be the minimum spanning trees of \(G\) and \(G'\), respectively, with total weights \(t\) and \(t'\). Which of the following statements is TRUE?
\(T' = T\) with total weight \(t' = t^2\)
\(T' = T\) with total weight \(t' < t^2\)
\(T' \neq T\) but total weight \(t' = t^2\)
None of the above
Correct Answer : MTA
Question Type : MCQ
Max Marks : 2
Negative Marks : 0.67
Question : 40
What is the minimal form of the Karnaugh map shown below? Assume that X denotes a don’t care term.
\(\bar{b} \bar{d}\)
\(\bar { b } \bar { d } + \bar{b} \bar{c}\)
\(\bar{b} \bar{d} + {a} \bar{b} \bar{c} {d}\)
\(\bar{b} \bar{d} + \bar{b} \bar{c} + \bar{c} \bar{d}\)
Correct Answer : B
Question Type : MCQ
Max Marks : 2
Negative Marks : 0.67
Question : 41
Consider the 3 processes, P1, P2 and P3 shown in the table.
The completion order of the 3 processes under the policies FCFS and RR2 (round robin scheduling with CPU quantum of 2 time units) are
FCFS: P1, P2, P3 RR2: P1, P2, P3
FCFS: P1, P3, P2 RR2: P1, P3, P2
FCFS: P1, P2, P3 RR2: P1, P3, P2
FCFS: P1, P3, P2 RR2: P1, P2, P3
Correct Answer : C
Question Type : MCQ
Max Marks : 2
Negative Marks : 0.67
Question : 42
Fetch_And_Add(X,i) is an atomic Read-Modify-Write instruction that reads the value of memory location X, increments it by the value i, and returns the old value of X. It is used in the pseudocode shown below to implement a busy-wait lock. L is an unsigned integer shared variable initialized to 0. The value of 0 corresponds to lock being available, while any non-zero value corresponds to the lock being not available.
AcquireLock(L){ while (Fetch_And_Add(L,1)) L = 1; } ReleaseLock(L){ L = 0; }
This implementation
fails as L can overflow
fails as L can take on a non-zero value when the lock is actually available
works correctly but may starve some processes
works correctly without starvation
Correct Answer : B
Question Type : MCQ
Max Marks : 2
Negative Marks : 0.67
Question : 43
Suppose a fair six-sided die is rolled once. If the value on the die is 1, 2, or 3, the die is rolled a second time. What is the probability that the sum total of values that turn up is at least 6?
10/21
5/12
2/3
1/6
Correct Answer : B
Question Type : MCQ
Max Marks : 2
Negative Marks : 0.67
Question : 44
An Internet Service Provider (ISP) has the following chunk of CIDR-based IP addresses available with it: 245.248.128.0/20. The ISP wants to give half of this chunk of addresses to Organization A, and a quarter to Organization B, while retaining the remaining with itself. Which of the following is a valid allocation of addresses to A and B?
245.248.136.0/21 and 245.248.128.0/22
245.248.128.0/21 and 245.248.128.0/22
245.248.132.0/22 and 245.248.132.0/21
245.248.136.0/24 and 245.248.132.0/21
Correct Answer : A
Question Type : MCQ
Max Marks : 2
Negative Marks : 0.67
Question : 45
Suppose a circular queue of capacity \((n −1)\) elements is implemented with an array of \(n\) elements. Assume that the insertion and deletion operations are carried out using REAR and FRONT as array index variables, respectively. Initially, REAR = FRONT = 0. The conditions to detect \(queue \ full\) and \(\text queue \ empty\) are
\(full\): (REAR+1) mod n == FRONT
\(empty\): REAR == FRONT
\(full\): (REAR+1) mod n == FRONT
\(empty\): (FRONT+1) mod n == REAR
\(full\): REAR == FRONT
\(empty\): (REAR+1) mod n == FRONT
\(full\): (FRONT+1) mod n == REAR
\(empty\): REAR == FRONT
Correct Answer : A
Question Type : MCQ
Max Marks : 2
Negative Marks : 0.67
Question : 46
Consider the program given below, in a block-structured pseudo-language with lexical scoping and nesting of procedures permitted.
Program main; Var ... Procedure A1; Var ... Call A2; End A1 Procedure A2; Var ... Procedure A21; Var ... Call A1; End A21 Call A21; End A2 Call A1; End main.
Consider the calling chain: \(Main \to A1 \to A2 \to A21 \to A1\)
The correct set of activation records along with their access links is given by
Correct Answer : D
Question Type : MCQ
Max Marks : 2
Negative Marks : 0.67
Question : 47
How many onto (or surjective) functions are there from an \(n\)-element \((n \geq 2)\) set to a 2-element set?
\(2^n\)
\(2^n - 1\)
\(2^n - 2\)
\(2(2^n - 2)\)
Correct Answer : C
Question Type : MCQ
Max Marks : 2
Negative Marks : 0.67
Question : 48
Let G be a complete undirected graph on 6 vertices. If vertices of G are labeled, then the number of distinct cycles of length 4 in G is equal to
15
30
90
360
Correct Answer : MTA
Question Type : MCQ
Max Marks : 2
Negative Marks : 0.67
Question : 49
A list of \(n\) strings, each of length \(n\), is sorted into lexicographic order using the merge-sort algorithm. The worst case running time of this computation is
\(O (n \ log \ n)\)
\(O (n^2 \log \ n)\)
\(O (n^2 + log \ n)\)
\(O (n^2)\)
Correct Answer : MTA
Question Type : MCQ
Max Marks : 2
Negative Marks : 0.67
Question : 50
Consider the directed graph shown in the figure below. There are multiple shortest paths between vertices S and T. Which one will be reported by Dijkstra’s shortest path algorithm? Assume that, in any iteration, the shortest path to a vertex v is updated only when a strictly shorter path to \(v\) is discovered.
SDT
SBDT
SACDT
SACET
Correct Answer : D
Question Type : MCQ
Max Marks : 2
Negative Marks : 0.67
Question : 51
A file system with 300 GByte disk uses a file descriptor with 8 direct block addresses, 1 indirect block address and 1 doubly indirect block address. The size of each disk block is 128 Bytes and the size of each disk block address is 8 Bytes. The maximum possible file size in this file system is
3 KBytes
35 KBytes
280 KBytes
dependent on the size of the disk
Correct Answer : B
Question Type : MCQ
Max Marks : 2
Negative Marks : 0.67
Question : 52
Consider the virtual page reference string
1, 2, 3, 2, 4, 1, 3, 2, 4, 1
on a demand paged virtual memory system running on a computer system that has main memory size of 3 page frames which are initially empty. Let LRU, FIFO and OPTIMAL denote the number of page faults under the corresponding page replacement policy. Then
OPTIMAL < LRU < FIFO
OPTIMAL < FIFO < LRU
OPTIMAL = LRU
OPTIMAL = FIFO
Correct Answer : B
Question Type : MCQ
Max Marks : 2
Negative Marks : 0.67
Question : 53
Suppose R1(A, B) and R2(C, D) are two relation schemas. Let r1 and r2 be the corresponding relation instances. B is a foreign key that refers to C in R2. If data in r1 and r2 satisfy referential integrity constraints, which of the following is ALWAYS TRUE?
\(\prod_{B}(r_{1})- \prod _{C}(r_{2})= \varnothing\)
\(\prod_{C}(r_{2})- \prod _{B}(r_{1})= \varnothing\)
\(\prod_{B}(r_{1}) = \prod _{C}(r_{2})\)
\(\prod_{B}(r_{1}) - \prod _{C}(r_{2}) \neq \varnothing\)
Correct Answer : A
Question Type : MCQ
Max Marks : 2
Negative Marks : 0.67
Question : 54
Consider a source computer (S) transmitting a file of size 106 bits to a destination computer (D) over a network of two routers (R1 and R2) and three links (L1, L2, and L3). L1 connects S to R1; L2 connects R1 to R2; and L3 connects R2 to D. Let each link be of length 100 km. Assume signals travel over each link at a speed of 108 meters per second. Assume that the link bandwidth on each link is 1Mbps. Let the file be broken down into 1000 packets each of size 1000 bits. Find the total sum of transmission and propagation delays in transmitting the file from S to D?
1005 ms
1010 ms
3000 ms
3003 ms
Correct Answer : A
Question Type : MCQ
Max Marks : 2
Negative Marks : 0.67
Question : 55
Consider an instance of TCP’s Additive Increase Multiplicative Decrease (AIMD) algorithm where the window size at the start of the slow start phase is 2 MSS and the threshold at the start of the first transmission is 8 MSS. Assume that a timeout occurs during the fifth transmission. Find the congestion window size at the end of the tenth transmission.
8 MSS
14 MSS
7 MSS
12 MSS
Correct Answer : MTA
Question Type : MCQ
Max Marks : 2
Negative Marks : 0.67
Question : 56
Consider the set of strings on {0,1} in which, \(every \ substring \ of \ 3 \ symbols\) has at most two zeros. For example, 001110 and 011001 are in the language, but 100010 is not. All strings of length less than 3 are also in the language. A partially completed DFA that accepts this language is shown below
The missing arcs in the DFA are
Correct Answer : D
Question Type : MCQ
Max Marks : 2
Negative Marks : 0.67
Question : 57
The height of a tree is defined as the number of edges on the longest path in the tree. The function shown in the pseudocode below is invoked as \(height(root)\) to compute the height of a binary tree rooted at the tree pointer \(root\).
The appropriate expressions for the two boxes B1 and B2 are
B1: (1+height(n \(\to\) right))
B2: (1+max(h1, h2))
B1: (height(n \(\to\) right))
B2: (1+max(h1,h2))
B1: height(n \(\to\) right)
B2: max(h1, h2)
B1: (1+ height(n \(\to\) right))
B2: max(h1, h2)
Correct Answer : A
Question Type : MCQ
Max Marks : 2
Negative Marks : 0.67
Question : 58
Consider the following C code segment.
int a, b, c = 0; void prtFun(void); main() { static int a = 1; /* Line 1 */ prtFun(); a += 1; prtFun(); printf(“ \n %d %d ”, a, b); } void prtFun(void) { static int a = 2; /* Line 2 */ int b = 1; a += ++b; printf(“ \n %d %d ”, a, b); }
What output will be generated by the given code segment?
\(\begin{array}{llll} 3 & & 1 & \\ 4 & & 1 & \\ 4 & & 2 & \end{array}\)
\(\begin{array}{lll} 4 & & 2 & \\ 6 & & 1 & \\ 6 & & 1 & \end{array}\)
\(\begin{array}{lll} 4 & & 2 & \\ 6 & & 2 & \\ 2 & & 0 & \end{array}\)
\(\begin{array}{lll} 3 & & 1 & \\ 5 & & 2 & \\ 5 & & 2 & \end{array}\)
Correct Answer : C
Question Type : MCQ
Max Marks : 2
Negative Marks : 0.67
Question : 59
Consider the following C code segment.
int a, b, c = 0; void prtFun(void); main() { static int a = 1; /* Line 1 */ prtFun(); a += 1; prtFun(); printf(“ \n %d %d ”, a, b); } void prtFun(void) { static int a = 2; /* Line 2 */ int b = 1; a += ++b; printf(“ \n %d %d ”, a, b); }
What output will be generated by the given code segment if:
Line 1 is replaced by auto int a = 1;
Line 2 is replaced by register int a = 2;
\(\begin{array}{ll} \text{3} & \text{1} \\ \text{4} & \text{1} \\ \text{4} & \text{2} \\ \end{array}\)
\(\begin{array}{ll} \text{4} & \text{2} \\ \text{6} & \text{1} \\ \text{6} & \text{1} \\ \end{array}\)
\(\begin{array}{ll} \text{4} & \text{2} \\ \text{6} & \text{2} \\ \text{2} & \text{0} \\ \end{array}\)
\(\begin{array}{ll} \text{4} & \text{2} \\ \text{4} & \text{2} \\ \text{2} & \text{0} \\ \end{array}\)
Correct Answer : D
Question Type : MCQ
Max Marks : 2
Negative Marks : 0.67
Question : 60
Consider the following relations A, B and C:
How many tuples does the result of the following relational algebra expression contain? Assume that the schema of \(A \cup B\) is the same as that of \(A\).
\((A\cup B)\bowtie _{A.Id > 40 \vee C.Id < 15} C\)
7
4
5
9
Correct Answer : A
Question Type : MCQ
Max Marks : 2
Negative Marks : 0.67
Question : 61
Consider the following relations A, B and C:
How many tuples does the result of the following SQL query contain?
SELECT A.Id FROM A WHERE A.Age > ALL (SELECT B.Age FROM B WHERE B.Name = ‘Arun’)
4
3
0
1
Correct Answer : B
Question Type : MCQ
Max Marks : 2
Negative Marks : 0.67
Question : 62
For the grammar below, a partial LL(1) parsing table is also presented along with the grammar. Entries that need to be filled are indicated as E1, E2, and E3. \(\varepsilon\) is the empty string, $ indicates end of input, and, | separates alternate right hand sides of productions.
S \(\to\) a A b B | b A a B | \(\varepsilon\)
A \(\to\) S
B \(\to\) S
The FIRST and FOLLOW sets for the non-terminals A and B are
FIRST(A) = {a, b, \(\varepsilon\)} = FIRST(B)
FOLLOW(A) = {a, b}
FOLLOW(B) = {a, b, $}
FIRST(A) = {a, b, $}
FIRST(B) = {a, b, \(\varepsilon\)} F
OLLOW(A) = {a, b}
FOLLOW(B) = {$}
FIRST(A) = {a, b, \(\varepsilon\)} = FIRST(B)
FOLLOW(A) = {a, b}
FOLLOW(B) = \(\phi\)
FIRST(A) = {a, b} = FIRST(B)
FOLLOW(A) = {a, b}
FOLLOW(B) = {a, b}
Correct Answer : A
Question Type : MCQ
Max Marks : 2
Negative Marks : 0.67
Question : 63
For the grammar below, a partial LL(1) parsing table is also presented along with the grammar. Entries that need to be filled are indicated as E1, E2, and E3. \(\varepsilon\) is the empty string, $ indicates end of input, and, | separates alternate right hand sides of productions.
S \(\to\) a A b B | b A a B | \(\varepsilon\)
A \(\to\) S
B \(\to\) S
The appropriate entries for E1, E2, and E3 are
E1: S \(\to\) aAbB, A \(\to\) S
E2: S \(\to\) bAaB, B \(\to\) S
E3: B \(\to\) S
E1: S \(\to\) aAbB, S \(\to\) \(\varepsilon\)
E2: S \(\to\) bAaB, S \(\to\) \(\varepsilon\)
E3: S \(\to\) \(\varepsilon\)
E1: S \(\to\) aAbB, S \(\to\) \(\varepsilon\)
E2: S \(\to\) bAaB, S \(\to\) \(\varepsilon\)
E3: B \(\to\) S
E1: A \(\to\) S, S \(\to\) \(\varepsilon\)
E2: B \(\to\) S, S \(\to\) \(\varepsilon\)
E3: B \(\to\) S
Correct Answer : C
Question Type : MCQ
Max Marks : 2
Negative Marks : 0.67
Question : 64
A computer has a 256 KByte, 4-way set associative, write back data cache with block size of 32 Bytes. The processor sends 32 bit addresses to the cache controller. Each cache tag directory entry contains, in addition to address tag, 2 valid bits, 1 modified bit and 1 replacement bit.
The number of bits in the tag field of an address is
11
14
16
27
Correct Answer : C
Question Type : MCQ
Max Marks : 2
Negative Marks : 0.67
Question : 65
A computer has a 256 KByte, 4-way set associative, write back data cache with block size of 32 Bytes. The processor sends 32 bit addresses to the cache controller. Each cache tag directory entry contains, in addition to address tag, 2 valid bits, 1 modified bit and 1 replacement bit.
The size of the cache tag directory is
160 Kbits
136 Kbits
40 Kbits
32 Kbits
Correct Answer : A
Question Type : MCQ
Max Marks : 2
Negative Marks : 0.67