## 2016 set-01

Question 1 |

Out of the following four sentences, select the most suitable sentence with respect to grammar and usage.

I will not leave the place until the minister does not meet me. | |

I will not leave the place until the minister doesn’t meet me. | |

I will not leave the place until the minister meet me. | |

I will not leave the place until the minister meets me. |

Question 1 Explanation:

In option A and B, 'not' is already embedded until so both are incorrect.

Minister is a singular person, with a singular object, so verb ends with 's'. So option C is incorrect.

Option 'D' is correct.

Minister is a singular person, with a singular object, so verb ends with 's'. So option C is incorrect.

Option 'D' is correct.

Question 2 |

A rewording of something written or spoken is a ______________.

paraphrase | |

paradox | |

paradigm | |

paraffin |

Question 2 Explanation:

Paraphase means that "express the meaning of (something written or spoken) using different words.

Question 3 |

figurative | |

collateral | |

literal | |

figurine |

Question 3 Explanation:

Figurative means that "departing from a literal use of words"; Metaphorical.

The use of the metaphorical words to explain about the thoughts instead of literal use of them.

The use of the metaphorical words to explain about the thoughts instead of literal use of them.

Question 4 |

If ‘relftaga’ means carefree, ‘otaga’ means careful and ‘fertaga’ means careless, which of the following could mean ‘aftercare’?

zentaga | |

tagafer | |

tagazen | |

relffer |

Question 4 Explanation:

relftaga - carefree → (1)

otaga - careful → (2)

fertaga - careless → (3)

From (1) & (2),

taga = care (and it is in the first half of the word)

From (3),

fer = less

Aftercare - tagazen

Care is in the second half of the word ⇒ taga should be in the first half.

otaga - careful → (2)

fertaga - careless → (3)

From (1) & (2),

taga = care (and it is in the first half of the word)

From (3),

fer = less

Aftercare - tagazen

Care is in the second half of the word ⇒ taga should be in the first half.

Question 5 |

A cube is built using 64 cubic blocks of side one unit. After it is built, one cubic block is removed from every corner of the cube. The resulting surface area of the body (in square units) after the removal is __________.

56 | |

64 | |

72 | |

96 |

Question 5 Explanation:

64 cubic blocks are used to make the cube

⇒ Side of cube = 4

Surface area of cube = 6s

Each corner block is associated with three faces of cube. When they are removed, three new faces are exposed, thus there appears no net change in the exposed surface area.

Hence, Surface area = 96

⇒ Side of cube = 4

Surface area of cube = 6s

^{2}= 6 × 4^{2}= 96Each corner block is associated with three faces of cube. When they are removed, three new faces are exposed, thus there appears no net change in the exposed surface area.

Hence, Surface area = 96

Question 6 |

Elegance | |

Executive | |

Smooth | |

Soft |

Question 6 Explanation:

Revenue from Elegance = (27300+25222+28976+21012)×48 = Rs. 4920480

Revenue from Smooth = (20009+19392+22429+18229)×63 = Rs. 5043717

Revenue from Soft = (17602+18445+19544+16595)×78 = Rs.5630508

Revenue from Executive = (9999+8942+10234+10109)×173 = Rs. 6796132

Clearly, Executive contributes the greatest fraction to the revenue of the company as the revenue from it is the highest.

Revenue from Smooth = (20009+19392+22429+18229)×63 = Rs. 5043717

Revenue from Soft = (17602+18445+19544+16595)×78 = Rs.5630508

Revenue from Executive = (9999+8942+10234+10109)×173 = Rs. 6796132

Clearly, Executive contributes the greatest fraction to the revenue of the company as the revenue from it is the highest.

Question 7 |

Indian currency notes show the denomination indicated in at least seventeen languages. If this is not an indication of the nation’s diversity, nothing else is.
Which of the following can be logically inferred from the above sentences?

India is a country of exactly seventeen languages. | |

Linguistic pluralism is the only indicator of a nation’s diversity. | |

Indian currency notes have sufficient space for all the Indian languages. | |

Linguistic pluralism is strong evidence of India’s diversity. |

Question 7 Explanation:

Option D is Correct Answer.

Which is inferred from the statement.

Option A, B, C are incorrect which are not properly inferred from the statement.

Which is inferred from the statement.

Option A, B, C are incorrect which are not properly inferred from the statement.

Question 8 |

(i) only | |

(ii) only | |

(i) and (ii) | |

neither (i) nor (ii) |

Question 8 Explanation:

From statements I, II & IV, we can say that

All three can beat S.

But from statement III,

S loses to P only sometimes.

(ii) Cannot be inferred.

And in poker, the transitive law does not apply. This can be seen from statement III.

As S loses to P only sometimes which states that wins against P most of the time.

So, (i) cannot be logically inferred.

All three can beat S.

But from statement III,

S loses to P only sometimes.

(ii) Cannot be inferred.

And in poker, the transitive law does not apply. This can be seen from statement III.

As S loses to P only sometimes which states that wins against P most of the time.

So, (i) cannot be logically inferred.

Question 9 |

If f(x) = 2x

^{7}+ 3x - 5, which of the following is a factor of f(x)?(x ^{3} +8) | |

(x-1) | |

(2x-5) | |

(x+1) |

Question 9 Explanation:

f(x)=2x

For (x - a) to be a factor of f(x)

f(a) = 0

From options,

Only a=1, satisfies the above equation

∴ (x - 1) is a factor of f(x).

^{7}+3x - 5For (x - a) to be a factor of f(x)

f(a) = 0

From options,

Only a=1, satisfies the above equation

∴ (x - 1) is a factor of f(x).

Question 10 |

In a process, the number of cycles to failure decreases exponentially with an increase in load. At a load of 80 units, it takes 100 cycles for failure. When the load is halved, it takes 10000 cycles for failure. The load for which the failure will happen in 5000 cycles is ________.

40.00 | |

46.02 | |

60.01 | |

92.02 |

Question 10 Explanation:

Given,

Number of cycles to failure decreases exponentially with an increase in load.

Let, Load=x, Cycles to failure=y

x/2 = y

and in general, x/n = y

Using option elimination procedure,

a) Load=40

When load is halved, it takes 10000 cycles for failure

80/2 = (100)

40 = 10000

It is wrong.

d) A load of 92.02 units will definitely require more than 80 units. So, it is wrong.

c) Load = 60.01 units

From general equation,

3/4 (80) = 60.01 = 10

Which is wrong

∴ Option B is correct.

Number of cycles to failure decreases exponentially with an increase in load.

Let, Load=x, Cycles to failure=y

x/2 = y

^{2}, x/3 = y^{3}, x/4 = y^{4}and in general, x/n = y

^{n}Using option elimination procedure,

a) Load=40

When load is halved, it takes 10000 cycles for failure

80/2 = (100)

^{2}40 = 10000

It is wrong.

d) A load of 92.02 units will definitely require more than 80 units. So, it is wrong.

c) Load = 60.01 units

From general equation,

3/4 (80) = 60.01 = 10

^{4/3}= 22 cyclesWhich is wrong

∴ Option B is correct.

Question 11 |

11 | |

12 | |

13 | |

14 |

Question 11 Explanation:

Given,

~((p→q) ∧ (~r ∨ ~S))

⇒ first simplify the given statement by converging them to ∧, ∨

⇒ [~(p→q) ∨ (~(~r ∨ ~s)]

Demorgan’s law:

⇒ [~(~p ∨ q) ∨ (r ∧ s) ] ∵p→q ≡ ~p ∨ q

⇒ [(p ∧ ~q) ∨ (r ∧ s)]

p ∧ ~q is {8,9,10,11,12} ∧ {not a composite number} i.e. {11}

r ∧ s is {perfect square} ∧ {prime} i.e. no answer

So, the one and only answer is 11.

~((p→q) ∧ (~r ∨ ~S))

⇒ first simplify the given statement by converging them to ∧, ∨

⇒ [~(p→q) ∨ (~(~r ∨ ~s)]

Demorgan’s law:

⇒ [~(~p ∨ q) ∨ (r ∧ s) ] ∵p→q ≡ ~p ∨ q

⇒ [(p ∧ ~q) ∨ (r ∧ s)]

p ∧ ~q is {8,9,10,11,12} ∧ {not a composite number} i.e. {11}

r ∧ s is {perfect square} ∧ {prime} i.e. no answer

So, the one and only answer is 11.

Question 12 |

Let a

_{n}be the number of n-bit strings that do NOT contain two consecutive 1s. Which one of the following is the recurrence relation for a_{n}?a _{n} = a_{(n-1)}+2a_{(n-2)} | |

a _{n} = a_{(n-1)}+a_{(n-2)} | |

a _{n} = 2a_{(n-1)}+a_{(n-2)} | |

a _{n} = 2a_{(n-1)}+2a_{(n-2)} |

Question 12 Explanation:

a

If n=1, we have {0,1} # Occurrences = 2

If n=2, we have {00,01,10} # Occurrences = 3

If n=3, we have {000,001,010,100,101} # Occurrences = 5

It is evident that a

Similarly, a

_{n}= number of n-bit strings, that do not have two consecutive 1’s.If n=1, we have {0,1} # Occurrences = 2

If n=2, we have {00,01,10} # Occurrences = 3

If n=3, we have {000,001,010,100,101} # Occurrences = 5

It is evident that a

_{3}= a_{1}+ a_{2}Similarly, a

_{n}= a_{n-1}+ a_{n-2}Question 14 |

A probability density function on the interval [a, 1] is given by 1/x

^{2}and outside this interval the value of the function is zero. The value of a is _________.0.7 | |

0.6 | |

0.5 | |

0.8 |

Question 14 Explanation:

The property of probability density function is area under curve = 1

or

where (a, b) is internal and f(x) is probability density function.

Given,

f(x) = 1/x

The area under curve,

-1 + 1/a = 1

1/a = 2

a = 0.5

or

where (a, b) is internal and f(x) is probability density function.

Given,

f(x) = 1/x

^{2}, a≤x≤1The area under curve,

-1 + 1/a = 1

1/a = 2

a = 0.5

Question 15 |

Two eigenvalues of a 3×3 real matrix P are (2+√-1) and 3. The determinant of P is __________.

18 | |

15 | |

17 | |

16 |

Question 15 Explanation:

If an eigen value of a matrix is a complex number, then there will be other eigen value, which is conjugate of the complex eigen value.

So, For the given 3×3 matrix there would be 3 eigen values.

Given eigen values are : 2+i and 3.

So the third eigen value should be 2-i.

As per the theorems, the determinant of the matrix is the product of the eigen values. So the determinant is (2+i)*(2-i)*3 = 15.

So, For the given 3×3 matrix there would be 3 eigen values.

Given eigen values are : 2+i and 3.

So the third eigen value should be 2-i.

As per the theorems, the determinant of the matrix is the product of the eigen values. So the determinant is (2+i)*(2-i)*3 = 15.

Question 16 |

Question 16 Explanation:

Ex-OR satisfies all the properties. Hence,

Question 17 |

The 16-bit 2’s complement representation of an integer is 1111 1111 1111 0101; its decimal representation is __________.

-11 | |

-12 | |

-13 | |

-14 |

Question 17 Explanation:

Given number is 1111 1111 1111 0101.

It is a negative number because MSB is 1.

Magnitude of 1111 1111 1111 0101 is 2’s complement of 1111 1111 1111 0101.

1111 1111 1111 0101

0000 0000 0000 1010 ⃪ 1’s Complement

0000 0000 0000 1011 ⃪ 2’s complement

= (11)

Hence, 1111 1111 1111 0101 = -11

It is a negative number because MSB is 1.

Magnitude of 1111 1111 1111 0101 is 2’s complement of 1111 1111 1111 0101.

1111 1111 1111 0101

0000 0000 0000 1010 ⃪ 1’s Complement

0000 0000 0000 1011 ⃪ 2’s complement

= (11)

_{10}Hence, 1111 1111 1111 0101 = -11

Question 18 |

We want to design a synchronous counter that counts the sequence 0-1-0-2-0-3 and then repeats. The minimum number of J-K ﬂip-ﬂops required to implement this counter is __________.

4 | |

5 | |

6 | |

7 |

Question 18 Explanation:

Given sequence is 0-1-0-2-0-3

There are 3 transitions from 0.

Hence ⌈log

There are 3 transitions from 0.

Hence ⌈log

_{2}^{3}⌉=2 bits have to be added to the existing 2 bits to represent 4 unique states.Question 19 |

A processor can support a maximum memory of 4GB, where the memory is word-addressable (a word consists of two bytes). The size of the address bus of the processor is at least _________ bits.

32 | |

34 | |

31 | |

33 |

Question 19 Explanation:

Maximum Memory = 4GB = 2

Size of a word = 2 bytes

Therefore, Number of words = 2

So, we require 31 bits for the address bus of the processor.

^{32}bytesSize of a word = 2 bytes

Therefore, Number of words = 2

^{32}/ 2 = 2^{31}So, we require 31 bits for the address bus of the processor.

Question 20 |

A queue is implemented using an array such that ENQUEUE and DEQUEUE operations are performed efﬁciently. Which one of the following statements is

**CORRECT**(n refers to the number of items in the queue)?Both operations can be performed in O(1) time | |

At most one operation can be performed in O(1) time but the worst case time for the other operation will be Ω(n) | |

The worst case time complexity for both operations will be Ω(n) | |

Worst case time complexity for both operations will be Ω(logn) |

Question 20 Explanation:

Since it is mentioned in the question that both of the operations are performed efficiently. Hence even the worst case time complexity will be O(1) by the use of the Circular queue there won't be any need of shifting in the array.

Question 21 |

7 | |

9 | |

8 | |

6 |

Question 21 Explanation:

Different topological orderings of the vertices of the graph are:

It is observed that (a) is the starting vertex & (f) is the final one.

Also observed that c must come after b & e must come after d.

So,

Hence, there are 6 different topological orderings can be derived.

It is observed that (a) is the starting vertex & (f) is the final one.

Also observed that c must come after b & e must come after d.

So,

Hence, there are 6 different topological orderings can be derived.

Question 22 |

f(s,*s) | |

i= f(i,s) | |

f(i,*s) | |

f(i,*p) |

Question 22 Explanation:

int i = 100;

short s = 12;

short *p = &s;

_______ // call to f ( ) :: (void f(int,short);)

It is clearly mentioned the return type of f is void.

By doing option elimination

(A) & (C) can be eliminated as s is short variable and not a pointer variable.

(B) i = f(i, s) is false because f’s return type is void, but here shown as int.

(D) f(i, *p)

i = 100

*p = 12

Hence TRUE

short s = 12;

short *p = &s;

_______ // call to f ( ) :: (void f(int,short);)

It is clearly mentioned the return type of f is void.

By doing option elimination

(A) & (C) can be eliminated as s is short variable and not a pointer variable.

(B) i = f(i, s) is false because f’s return type is void, but here shown as int.

(D) f(i, *p)

i = 100

*p = 12

Hence TRUE

Question 23 |

The worst case running times of Insertion sort, Merge sort and Quick sort, respectively, are:

Θ(nlogn),Θ(nlogn),and Θ(n ^{2}) | |

Θ(n ^{2} ),Θ(n^{2} ),and Θ(nlogn) | |

Θ(n ^{2}),Θ(nlogn),and Θ(nlogn) | |

Θ(n ^{2}),Θ(nlogn),and Θ(n^{2}) |

Question 23 Explanation:

Question 24 |

P only | |

Q only | |

Neither P nor Q | |

Both P and Q |

Question 24 Explanation:

Given undirected weighted graph with distinct positive edges. Every edge weight is increased by the same value say,

P: Minimum Spanning Tree will not change ABC in both the cases.

Q: Shortest path will change because in 1st figure the path from A to C calculated as ABC but in fig.2, it is AC (Direct path).

P: Minimum Spanning Tree will not change ABC in both the cases.

Q: Shortest path will change because in 1st figure the path from A to C calculated as ABC but in fig.2, it is AC (Direct path).

Question 25 |

2016 | |

2017 | |

2018 | |

2019 |

Question 25 Explanation:

For the first mystery (&a, &b);

temp = ptr b

ptr b = ptr a

ptr a = temp

If (a

Hence, a = 2016 will be printed.

Question 26 |

{a ^{n}b^{m} |n,m≥0} | |

{w ∈ {a,b}* | w has equal number of a’s and b’s} | |

{a ^{n} |n≥0}∪{b^{n} |n≥0}∪{a^{n} b(sup>n|n≥0} | |

{a,b}* |

Question 26 Explanation:

From the given grammar we can draw the DFA,

Question 27 |

I and IV only | |

II and III only | |

III and IV only | |

II and IV only |

Question 27 Explanation:

Statement I is decidable, as we can make product automata by using N

Statement II is decidable, as for CFG we have membership algorithm, hence it is decidable.

But for problems in statement III and IV, there doesn’t exist any algorithm which can decide it.

_{1}and N_{2}and can decide whether the resulting Product automata’s language is phi or not.Statement II is decidable, as for CFG we have membership algorithm, hence it is decidable.

But for problems in statement III and IV, there doesn’t exist any algorithm which can decide it.

Question 28 |

Which one of the following regular expressions represents the language:

*the set of all binary strings having two consecutive*0*s and two consecutive*1*s*?(0+1)* 0011(0+1)*+(0+1)* 1100(0+1)* | |

(0+1)* (00(0+1)* 11+11(0+1)* 00)(0+1)* | |

(0+1)* 00(0+1)*+(0+1)* 11(0+1)* | |

00(0+1)* 11+11(0+1)* 00 |

Question 28 Explanation:

Option A doesn’t generate string “001011” as it has two consecutive 0’s and two consecutive 1’s.

Option C generates string “00” which doesn’t have two consecutive 1’s.

Option D doesn’t generate string “00110” which has two consecutive 0’s and two consecutive 1’s.

Option C generates string “00” which doesn’t have two consecutive 1’s.

Option D doesn’t generate string “00110” which has two consecutive 0’s and two consecutive 1’s.

Question 29 |

10 | |

11 | |

12 | |

13 |

Question 29 Explanation:

In Static Single Assignment form (SSA) each assignment to a variable should be specified with distinct names. Generally, subscripts are used to distinguish each definition of variables.

In the given code segment, there are two assignments of the variable x

x = u - t;

x = y + w;

and three assignments of the variable y.

y = x * v;

y = t - z;

y = x * y

Hence, two variables viz x1, x2 should be used for specifying distinct assignments of x and for y it is named as y1, y2 and y3 for each assignment of y. Hence, total number of variables is 10 (x1, x2, y1, y2, y3, t, u, v, w, z), and there are 5 temporary variables.

Static Single Assignment form (SSA) of the given code segment is:

x1 = u - t;

y1 = x1 * v;

x2 = y1 + w;

y2 = t - z;

y3 = x2 * y2;

In the given code segment, there are two assignments of the variable x

x = u - t;

x = y + w;

and three assignments of the variable y.

y = x * v;

y = t - z;

y = x * y

Hence, two variables viz x1, x2 should be used for specifying distinct assignments of x and for y it is named as y1, y2 and y3 for each assignment of y. Hence, total number of variables is 10 (x1, x2, y1, y2, y3, t, u, v, w, z), and there are 5 temporary variables.

Static Single Assignment form (SSA) of the given code segment is:

x1 = u - t;

y1 = x1 * v;

x2 = y1 + w;

y2 = t - z;

y3 = x2 * y2;

Question 30 |

Consider an arbitrary set of CPU-bound processes with unequal CPU burst lengths submitted at the same time to a computer system. Which one of the following process scheduling algorithms would minimize the average waiting time in the ready queue?

Shortest remaining time ﬁrst | |

Round-robin with time quantum less than the shortest CPU burst | |

Uniform random | |

Highest priority ﬁrst with priority proportional to CPU burst length |

Question 30 Explanation:

From the above question, we can get the following information.

We can consider an arbitrary set of CPU-bound processes with unequal CPU burst lengths submitted at the same time to a computer system. We have to choose the appropriate process scheduling algorithms, which would minimize the average waiting time in the ready queue.

Waiting time is the time for which process is ready to run but not executed by CPU scheduler.

In all CPU Scheduling algorithms, shortest job first is optimal.

It gives minimum turnaround time, minimum average waiting time and high throughput and the most important thing is that shortest remaining time first is the preemptive version of shortest job first.

This scheduling algorithm may lead to starvation because if the short processes are added to the CPU scheduler continuously then the currently running process will never be able to execute as they will get pre-empted but here all the processes are arrived at same time so there will be no issue such as starvation. SRTF would be same as SJF.

So, A is the answer. Shortest remaining time first.

We can consider an arbitrary set of CPU-bound processes with unequal CPU burst lengths submitted at the same time to a computer system. We have to choose the appropriate process scheduling algorithms, which would minimize the average waiting time in the ready queue.

Waiting time is the time for which process is ready to run but not executed by CPU scheduler.

In all CPU Scheduling algorithms, shortest job first is optimal.

It gives minimum turnaround time, minimum average waiting time and high throughput and the most important thing is that shortest remaining time first is the preemptive version of shortest job first.

This scheduling algorithm may lead to starvation because if the short processes are added to the CPU scheduler continuously then the currently running process will never be able to execute as they will get pre-empted but here all the processes are arrived at same time so there will be no issue such as starvation. SRTF would be same as SJF.

So, A is the answer. Shortest remaining time first.

Question 31 |

Which of the following is

**NOT**a superkey in a relational schema with attributes V,W, X,Y, Z and primary key V Y?VXYZ | |

VWXZ | |

VWXY | |

VWXYZ |

Question 31 Explanation:

It is given that “VY” is a primary key of the relational schema.

Any superset of “VY” is a super key. So, option (B) does not contain “Y”.

Any superset of “VY” is a super key. So, option (B) does not contain “Y”.

Question 32 |

Which one of the following is

**NOT**a part of the**ACID**properties of database transactions?Atomicity | |

Consistency | |

Isolation | |

Deadlock-freedom |

Question 32 Explanation:

A transaction in a database system must maintain Atomicity, Consistency, Isolation and Durability – commonly known as ACID properties.

So, Deadlock – freedom is not there in the ACID properties.

So, Deadlock – freedom is not there in the ACID properties.

Question 33 |

1NF | |

2NF | |

3NF | |

BCNF |

Question 33 Explanation:

Journal (V, N, S, E, T, Y, P)

V – VOLUME

N – NUMBER

S – STARTPAGE

E – ENDPAGE

T – TITLE

Y – YEAR

P – PRICE

Primary key: (V, N, S, E)

FD set:

(V, N, S, E) → T

(V, N) → Y

(V, N, S, E) →P

In (V, N) → Y; V, N is a part of the key and Y is non-prime attribute. So, it is a partial dependency.

Now, the schema “Journal” is in 1NF but not in 2NF.

The database is redesigned as follows:

Both R

Therefore, 2NF is the weakest normal form that the new database satisfies, but the old one does not.

V – VOLUME

N – NUMBER

S – STARTPAGE

E – ENDPAGE

T – TITLE

Y – YEAR

P – PRICE

Primary key: (V, N, S, E)

FD set:

(V, N, S, E) → T

(V, N) → Y

(V, N, S, E) →P

In (V, N) → Y; V, N is a part of the key and Y is non-prime attribute. So, it is a partial dependency.

Now, the schema “Journal” is in 1NF but not in 2NF.

The database is redesigned as follows:

Both R

_{1}and R_{2}are in BCNF.Therefore, 2NF is the weakest normal form that the new database satisfies, but the old one does not.

Question 34 |

Which one of the following protocols is

**NOT**used to resolve one form of address to another one?DNS | |

ARP | |

DHCP | |

RARP |

Question 34 Explanation:

DHCP is dynamic host configuration protocol: allocates one of the unused IP address.

Except DHCP, remaining all the protocols are used to resolve one form of address to another one.

I. DNS is going to convert hostname to IP address.

II. ARP is going to convert IP to MAC.

III. DHCP is going to assign IP dynamically.

IV. RARP is going to convert MAC to IP.

Except DHCP, remaining all the protocols are used to resolve one form of address to another one.

I. DNS is going to convert hostname to IP address.

II. ARP is going to convert IP to MAC.

III. DHCP is going to assign IP dynamically.

IV. RARP is going to convert MAC to IP.

Question 35 |

(i) and (ii) only | |

(ii) and (iii) only | |

(ii) and (iv) only | |

(iv) only |

Question 35 Explanation:

Stateless protocol is a communications protocol in which no information is retained by either sender or receiver.

A protocol that requires keeping of the internal state on the server is known as a stateful protocol.

Stateless - HTTP, IP

Stateful - FTP, SMTP, POP3, TCP

TCP is stateful as it maintains connection information across multiple transfers, but TCP is a Transport layer protocol.

FTP and POP3 is stateful Application layer protocol.

A protocol that requires keeping of the internal state on the server is known as a stateful protocol.

Stateless - HTTP, IP

Stateful - FTP, SMTP, POP3, TCP

TCP is stateful as it maintains connection information across multiple transfers, but TCP is a Transport layer protocol.

FTP and POP3 is stateful Application layer protocol.

Question 36 |

The coefﬁcient of x

^{12}in (x^{3 }+ x^{4 }+ x^{5 }+ x^{6 }+ ...)^{3}is ___________.10 | |

11 | |

12 | |

13 |

Question 36 Explanation:

Co-efficient of x

⇒[x

= x

First Reduction:

As x

Here, m=3,k=3, the coefficient =

^{12}in (x^{3}+x^{4}+x^{5}+x^{6}+...)^{3}⇒[x

^{3}(1+x+x^{2}+x^{3}+...)]^{3}= x

^{9}(1+x+x^{2}+x^{3}+...)^{3}First Reduction:

As x

^{9}is out of the series, we need to find the co-efficient of x^{3}in (1+x+x^{2}+⋯)^{3}Here, m=3,k=3, the coefficient =

^{5}C_{3}=5!/2!3!=10Question 37 |

Consider the recurrence relation a

_{1 }= 8, a_{n }= 6n^{2 }+ 2n + a_{n-1}. Let a_{99 }= K × 10^{4}. The value of K is ___________.198 | |

199 | |

200 | |

201 |

Question 37 Explanation:

a

Replace a

⇒a

Given that a

⇒a

=6n

=6(n

Sum of n

Sum of n=(n(n+1))/2

=6×(n(n+1)(2n+1))/6+2×(n(n+1))/2

=n(n+1)[1+2n+1]

=n(n+1)[2n+2]

=2n(n+1)

Given a

a

∴k=198

_{n}= 6n^{2}+2n+a_{(n-1)}Replace a

_{(n-1)}⇒a

_{n}=6n^{2}+2n+6(n-1)^{2}+2(n-1)+6(n-2)^{2}+2(n-2)+⋯a_{1}Given that a

_{1}=8, replace it⇒a

_{n}=6n^{2}+2n+6(n-1)^{2}+2(n-1)+6(n-2)^{2}+2(n-2)+⋯8=6n

^{2}+2n+6(n-1)^{2}+2(n-1)+6(n-2)^{2}+2(n-2)+⋯+6(1)^{2}+2(1)=6(n

^{2}+(n-1)^{2}+(n-2)^{2}+⋯+2^{2}+1^{2})+2(n+(n-1)+⋯1)Sum of n

^{2}=(n(n+1)(2n+1))/6Sum of n=(n(n+1))/2

=6×(n(n+1)(2n+1))/6+2×(n(n+1))/2

=n(n+1)[1+2n+1]

=n(n+1)[2n+2]

=2n(n+1)

^{2}Given a

_{99}=k×10^{4}a

_{99}=2(99) (100)^{2}=198×10^{4}∴k=198

Question 38 |

2 | |

3 | |

4 | |

5 |

Question 38 Explanation:

f(n)= f(n⁄2) if n is even

f(n)= f(n+5) if n is odd

We can observe that

and f(5)=f(10)=f(15)=f(20)

Observe that f(11)=f(8)

f(12)=f(6)=f(3)

f(13)=f(9)=f(14)=f(7)=f(12)=f(6)=f(3)

=f(3)

f(14)=f(9)=f(12)=f(6)

=f(3)

f(16)=f(8)=f(4)=f(2)=f(1) [repeating]

So we can conclude that

‘R’ can have size only ‘two’ [one: multiple of 5’s, other: other than 5 multiples]

f(n)= f(n+5) if n is odd

We can observe that

and f(5)=f(10)=f(15)=f(20)

Observe that f(11)=f(8)

f(12)=f(6)=f(3)

f(13)=f(9)=f(14)=f(7)=f(12)=f(6)=f(3)

=f(3)

f(14)=f(9)=f(12)=f(6)

=f(3)

f(16)=f(8)=f(4)=f(2)=f(1) [repeating]

So we can conclude that

‘R’ can have size only ‘two’ [one: multiple of 5’s, other: other than 5 multiples]

Question 39 |

0.33 | |

0.34 | |

0.35 | |

0.36 |

Question 39 Explanation:

If a coin is flipped twice, the possible outcomes {HH, HT, TH, TT}

Stop conditions:

If outcome = TH then Stop [output 4] ---------------①

else

outcome = HH/ HT then Stop [output N] --------------②

We get ‘y’ when we have ① i.e., ‘TH’ is output.

① can be preceded by ‘TT’ also, as ‘TT’ will reset ① again

Probability of getting y = TH + (TT)(TH) + (TT)(TT)(TH) + …

=1/2×1/2+1/2×1/2×1/2×1/2+...

=(1/4)/(1-1/4)

=1/3

=0.33

Stop conditions:

If outcome = TH then Stop [output 4] ---------------①

else

outcome = HH/ HT then Stop [output N] --------------②

We get ‘y’ when we have ① i.e., ‘TH’ is output.

① can be preceded by ‘TT’ also, as ‘TT’ will reset ① again

Probability of getting y = TH + (TT)(TH) + (TT)(TT)(TH) + …

=1/2×1/2+1/2×1/2×1/2×1/2+...

=(1/4)/(1-1/4)

=1/3

=0.33

Question 41 |

The size of the data count register of a

**DMA**controller is 16 bits. The processor needs to transfer a ﬁle of 29,154 kilobytes from disk to main memory. The memory is byte addressable. The minimum number of times the**DMA**controller needs to get the control of the system bus from the processor to transfer the ﬁle from the disk to main memory is ________.456 | |

457 | |

458 | |

459 |

Question 41 Explanation:

Since nothing is mentioned about the mode of DMA working whether it is cycle stealing mode or burst mode, we consider it as burst mode by default.

As the data count register of the DMA is 16 bits long in burst mode DMA transfers 2

To transfer 29,154 KB, no. of times DMA needs to take control = (29,154 KB / 64KB) = 29,154/64 = 455.53, means 456 times.

As the data count register of the DMA is 16 bits long in burst mode DMA transfers 2

^{16}Bytes (= 64KB) once it gets the control.To transfer 29,154 KB, no. of times DMA needs to take control = (29,154 KB / 64KB) = 29,154/64 = 455.53, means 456 times.

Question 42 |

The stage delays in a 4-stage pipeline are 800, 500, 400 and 300 picoseconds. The ﬁrst stage (with delay 800 picoseconds) is replaced with a functionally equivalent design involving two stages with respective delays 600 and 350 picoseconds. The throughput increase of the pipeline is ________ percent.

33.33% | |

33.34% | |

33.35% | |

33.36% |

Question 42 Explanation:

In a pipelined processor the throughput is 1/clock cycle time. Cycle time = max of all stage delays. In the first case max stage delay = 800. So throughput = 1/800 initially. After replacing this stage with two stages of delays 600, 350... the cycle time = maximum stage delay = 600, so the new throughput = 1/600.

The new throughput > old throughput. And the increase in throughput = 1/600 - 1/800.

We calculate the percentage increase in throughput w.r.t initial throughput, so the % increase in throughput = (1/600 - 1/800) / (1/800) * 100 = ((800 / 600) - 1) * 100 = ((8/6) -1) * 100 = 33.33%

The new throughput > old throughput. And the increase in throughput = 1/600 - 1/800.

We calculate the percentage increase in throughput w.r.t initial throughput, so the % increase in throughput = (1/600 - 1/800) / (1/800) * 100 = ((800 / 600) - 1) * 100 = ((8/6) -1) * 100 = 33.33%

Question 43 |

Consider a carry lookahead adder for adding two n-bit integers, built using gates of fan-in at most two. The time to perform addition using this adder is __________.

Θ(1) | |

Θ(log(n)) | |

Θ(√n) | |

Θ(n) |

Question 43 Explanation:

Formula: θ(log

Where n is number of bits added

and k is fan-in of the gates.

As we are adding n-bit numbers and fan-in is at most 2, the solution is θ(log

_{k}(n))Where n is number of bits added

and k is fan-in of the gates.

As we are adding n-bit numbers and fan-in is at most 2, the solution is θ(log

_{2}(n)).Question 44 |

a != n | |

b != 0 | |

b > (a + 1) | |

b != a |

Question 44 Explanation:

main ( )

{

int arr [ ] = {3, 2, 1, 5, 4};

int n = sizeof(arr) / sizeof (arr[0]);

printf (max(arr, 5));

}

int max (int *p, int n)

{

int a = 0, b = n – 1;

(while (a!=b))

{

if (p[a] <= p[b])

{

a = a + 1;

}

else

{

b =b – 1;

}

}

return p[a];

}

The function computes the maximum value contained in an integer array p [ ] of size n (n >= 1).

If a = = b, means both are at same location & comparison ends.

{

int arr [ ] = {3, 2, 1, 5, 4};

int n = sizeof(arr) / sizeof (arr[0]);

printf (max(arr, 5));

}

int max (int *p, int n)

{

int a = 0, b = n – 1;

(while (a!=b))

{

if (p[a] <= p[b])

{

a = a + 1;

}

else

{

b =b – 1;

}

}

return p[a];

}

The function computes the maximum value contained in an integer array p [ ] of size n (n >= 1).

If a = = b, means both are at same location & comparison ends.

Question 45 |

3 1 2 2 1 3 4 4 4 | |

3 1 2 1 1 1 2 2 2 | |

3 1 2 2 1 3 4 | |

3 1 2 1 1 1 2 |

Question 45 Explanation:

Count (3)

static int d = 1

It prints 3, 1

d++; //d = 2

n>1, count(2)

prints 2, 2

d++; // d = 3

n>1, count(1)

prints 1, 3 → Here n = 1, so condition failed & printf (last statement) executes thrice & prints d

d++; //d=4 value as 4. For three function calls, static value retains. ∴ 312213444

Question 46 |

6, 2 | |

6, 6 | |

4, 2 | |

4, 4 |

Question 46 Explanation:

First m(a) is implemented, as there are no local variables in main ( ), it takes global a = 3;

m(3) is passed to m(y).

a = 1

a = 3 – 1 = 2

n(2) is passed to n(x).

Since it is dynamic scoping

x = 2 * 2 = 4 (a takes the value of its calling function not the global one).

The local x is now replaced in m(y) also.

Hence, it prints 4,4.

And we know it prints 6, 2 if static scoping is used. It is by default in C programming.

Question 47 |

An operator

*delete(i)*for a binary heap data structure is to be designed to delete the item in the*i*-th node. Assume that the heap is implemented in an array and*i*refers to the*i*-th index of the array. If the heap tree has depth*d*(number of edges on the path from the root to the farthest leaf), then what is the time complexity to re-ﬁx the heap efﬁciently after the removal of the element?O(1) | |

O(d) but not O(1) | |

O(2 ^{d}) but not O(d) | |

O(d 2 ^{d}) but not O(2^{d}) |

Question 47 Explanation:

→ If heap has n elements generally it takes O(n) to delete any arbitrary element.

→ Because we first need to find that element, O(n) time

Delete that element O(height) [deleting involves swapping particular element to rightmost leaf and then do heapify on that node].

**but here, we don't need to find that element, because in delete(i), i is index of that element.

Note: Delete time = O(height) = O(d)

→ Because we first need to find that element, O(n) time

Delete that element O(height) [deleting involves swapping particular element to rightmost leaf and then do heapify on that node].

**but here, we don't need to find that element, because in delete(i), i is index of that element.

Note: Delete time = O(height) = O(d)

Question 48 |

12 | |

13 | |

14 | |

15 |

Question 48 Explanation:

Let vertices be A, B, C and D.

x directly connects C to D.

The shortest path (excluding x) from C to D is of weight 12 (C-B-A-D).

x directly connects C to D.

The shortest path (excluding x) from C to D is of weight 12 (C-B-A-D).

Question 49 |

Let G be a complete undirected graph on 4 vertices, having 6 edges with weights being 1, 2, 3, 4, 5, and 6. The maximum possible weight that a minimum weight spanning tree of G can have is __________.

7 | |

8 | |

9 | |

10 |

Question 49 Explanation:

Let G be a complete undirected graph with 4 vertices & 6 edges so according to graph theory, if we use Prim’s / Kruskal’s algorithm, the graph looks like

Now consider vertex A to make Minimum spanning tree with Maximum weights.

As weights are 1, 2, 3, 4, 5, 6. AB, AD, AC takes maximum weights 4, 5, 6 respectively.

Next consider vertex B, BA = 4, and minimum spanning tree with maximum weight next is BD & BC takes 2, 3 respectively.

And the last edge CD takes 1.

So, 1+2+4 in our graph will be the Minimum spanning tree with maximum weights.

Now consider vertex A to make Minimum spanning tree with Maximum weights.

As weights are 1, 2, 3, 4, 5, 6. AB, AD, AC takes maximum weights 4, 5, 6 respectively.

Next consider vertex B, BA = 4, and minimum spanning tree with maximum weight next is BD & BC takes 2, 3 respectively.

And the last edge CD takes 1.

So, 1+2+4 in our graph will be the Minimum spanning tree with maximum weights.

Question 50 |

I only | |

II only | |

both I and II | |

neither I nor II |

Question 50 Explanation:

Statement-1: False

The MSTs of G may or may not include the lightest edge. Take rectangular graph labelled with P,Q,R,S. Connect with P-Q=5, Q-R=6, R-S=8, S-P=9, P-R=7. When we are forming a cycle R-S-P-R. P-R is the lightest edge of the cycle. The MST abcd with cost 11 P-Q + Q-R + R-S does not include it.

Statement-2: True

Suppose there is a minimum spanning tree which contains e. If we add one more edge to the spanning tree we will create a cycle. Suppose we add edge e to the spanning tree which generated cycle C. We can reduce the cost of the minimum spanning tree if we choose an edge other than e from C for removal which implies that e must not be in minimum spanning tree and we get a contradiction

The MSTs of G may or may not include the lightest edge. Take rectangular graph labelled with P,Q,R,S. Connect with P-Q=5, Q-R=6, R-S=8, S-P=9, P-R=7. When we are forming a cycle R-S-P-R. P-R is the lightest edge of the cycle. The MST abcd with cost 11 P-Q + Q-R + R-S does not include it.

Statement-2: True

Suppose there is a minimum spanning tree which contains e. If we add one more edge to the spanning tree we will create a cycle. Suppose we add edge e to the spanning tree which generated cycle C. We can reduce the cost of the minimum spanning tree if we choose an edge other than e from C for removal which implies that e must not be in minimum spanning tree and we get a contradiction

Question 51 |

256 | |

257 | |

258 | |

259 |

Question 51 Explanation:

The maximum possible number of iterations of the while loop in this algorithm is:

Try to solve it for 3 numbers [1. 2, 3].

Step 1: Initially Queue contains 3 elements so after 5 while loop iterations queue contains 3, 2 and stack contains 1.

Step 2: Now after 3 more while loop iterations, Queue contains 3 and stack contains 1, 2 (TOS = 2).

Step 3: After 1 more while loop iteration, push 3 onto the stack so queue is empty and stack contains 1, 2, 3 {top = 3}.

So total number of iterations will be 5 + 3 + 1 = 9

i.e., for 3 it is 9 iterations (3*3)

for 4 it is 16 iterations (4*4)

Given 16 numbers so 16 * 16 = 256

Try to solve it for 3 numbers [1. 2, 3].

Step 1: Initially Queue contains 3 elements so after 5 while loop iterations queue contains 3, 2 and stack contains 1.

Step 2: Now after 3 more while loop iterations, Queue contains 3 and stack contains 1, 2 (TOS = 2).

Step 3: After 1 more while loop iteration, push 3 onto the stack so queue is empty and stack contains 1, 2, 3 {top = 3}.

So total number of iterations will be 5 + 3 + 1 = 9

i.e., for 3 it is 9 iterations (3*3)

for 4 it is 16 iterations (4*4)

Given 16 numbers so 16 * 16 = 256

Question 52 |

{a ^{m} b^{n}│m > 0 or n > 0} and {a^{m} b^{n} |m > 0 and n > 0} | |

{a ^{m} b^{n}│m > 0 and n > 0} and {a^{m} b^{n} |m > 0 or n≥0} | |

{a ^{m} b^{n}│m≥0 or n > 0} and {a^{m} b^{n} |m > 0 and n > 0} | |

{a ^{m} b^{n}│m≥0 and n > 0} and {a^{m} b^{n} |m > 0 or n > 0} |

Question 52 Explanation:

G

G

_{1}: S→aS; will generate any number of a’s and then we can have any number of b’s (greater than zero) after a’s by using he productions S→B and B→b|bBG

_{2}: By using S→aA and then A→aA | ϵ we can have only any number of a’s (greater than zero) OR we can use A→B and B→bB | ϵ to add any number of b’s after a’s OR by using S→bB and B→bB | ϵ we can have only any number of b’s (greater than zero).Question 53 |

L ={a ^{n} b^{n}│n≥0} and is not accepted by any ﬁnite automata | |

L ={a ^{n} |n≥0}∪{a^{n}b^{n}|n≥0} and is not accepted by any deterministic PDA | |

L is not accepted by any Turing machine that halts on every input | |

L ={a ^{n} |n≥0}∪{a^{n} b^{n} |n≥0} and is deterministic context-free |

Question 53 Explanation:

In this PDA, we can give labels to state as q

This PDA accepts the string by both ways i.e. by using q

Since q

Hence L = {a

_{0}, q_{1}, q_{2}where q_{0}and q_{2}are final states.This PDA accepts the string by both ways i.e. by using q

_{0}accepts as final state and by using q_{2}it accepts as empty stack.Since q

_{0}is initial as well as final state, so it can accept any number of a’s (including zero a’s) and by using q_{2}as empty stack it accept strings which has equal number of a’s and b’s (b’s comes after a’s).Hence L = {a

^{n}| n≥0} ∪ { a^{n}b^{n}| n≥0}.Question 54 |

W can be recursively enumerable and Z is recursive. | |

W can be recursive and Z is recursively enumerable. | |

W is not recursively enumerable and Z is recursive. | |

W is not recursively enumerable and Z is not recursive. |

Question 54 Explanation:

The rules are: If A ≤

Rule 1: If B is recursive then A is recursive

Rule 2: If B is recursively enumerable then A is recursively enumerable

Rule 3: If A is not recursively enumerable then B is not recursively enumerable

Since X is recursive and recursive language is closed under compliment, so is also recursive.

: By rule 3, W is not recursively enumerable.

: By rule 1, Z is recursive.

Hence W is not recursively enumerable and Z is recursive.

_{p}BRule 1: If B is recursive then A is recursive

Rule 2: If B is recursively enumerable then A is recursively enumerable

Rule 3: If A is not recursively enumerable then B is not recursively enumerable

Since X is recursive and recursive language is closed under compliment, so is also recursive.

: By rule 3, W is not recursively enumerable.

: By rule 1, Z is recursive.

Hence W is not recursively enumerable and Z is recursive.

Question 55 |

9 | |

10 | |

11 | |

12 |

Question 55 Explanation:

+ has highest precedence, so it will be evaluated first.

2−5+1−7*3 = 2−(5+1) −7*3 = 2−6−7*3

Now, − has more precedence than *, so sub will be evaluated before * and – has right associative so (6−7) will be evaluated first.

2−6−7*3 = (2− (6−7)) *3 = (2 – (−1)) *3 = 3*3 = 9

2−5+1−7*3 = 2−(5+1) −7*3 = 2−6−7*3

Now, − has more precedence than *, so sub will be evaluated before * and – has right associative so (6−7) will be evaluated first.

2−6−7*3 = (2− (6−7)) *3 = (2 – (−1)) *3 = 3*3 = 9

Question 56 |

1 3 2 | |

2 2 3 | |

2 3 1 | |

syntax error |

Question 56 Explanation:

By using bottom up parser, the output will be “2 3 1”

Question 57 |

Consider a computer system with 40-bit virtual addressing and page size of sixteen kilobytes. If the computer system has a one-level page table per process and each page table entry requires 48 bits, then the size of the per-process page table is __________ megabytes.

384 MB | |

385 MB | |

386 MB | |

387 MB |

Question 57 Explanation:

From the above question, we got the following information.

Size of memory = 2

No. of pages = size of Memory / page size = 2

Size of page table = 2

Size of memory = 2

^{40}and Page size = 16 KB = 2^{14}.No. of pages = size of Memory / page size = 2

^{40}/ 2^{14}= 2^{26}Size of page table = 2

^{26}* 48 / 8 bytes = 2^{6}* 6 MB = 384 MB.Question 58 |

Consider a disk queue with requests for I/O to blocks on cylinders 47, 38, 121, 191, 87, 11, 92, 10. The C-LOOK scheduling algorithm is used. The head is initially at cylinder number 63, moving towards larger cylinder numbers on its servicing pass. The cylinders are numbered from 0 to 199. The total head movement (in number of cylinders) incurred while servicing these requests is ___________.

346 | |

347 | |

348 | |

349 |

Question 58 Explanation:

From the question, we got the following information.

I/O to blocks on cylinders 47, 38, 121, 191, 87, 11, 92, 10. C-LOOK scheduling algorithm is used. Head is initially at cylinder number 63.

First start from 63

63 → 87 → 92 → 121 → 191 = 24 + 5 + 29 + 70 movements = 128

191 → 10 movements = 181

10 → 11 → 38 → 47 = 1 + 27 + 9 movements = 37

Total = 128 + 181 + 37 = 346

I/O to blocks on cylinders 47, 38, 121, 191, 87, 11, 92, 10. C-LOOK scheduling algorithm is used. Head is initially at cylinder number 63.

First start from 63

63 → 87 → 92 → 121 → 191 = 24 + 5 + 29 + 70 movements = 128

191 → 10 movements = 181

10 → 11 → 38 → 47 = 1 + 27 + 9 movements = 37

Total = 128 + 181 + 37 = 346

Question 59 |

Consider a computer system with ten physical page frames. The system is provided with an access sequence (a

_{1}, a_{2}, …, a_{20}, a_{1}, a_{2}, …, a_{20}), where each a_{i}is a distinct virtual page number. The difference in the number of page faults between the last-in-ﬁrst-out page replacement policy and the optimal page replacement policy is ___________.1 | |

2 | |

3 | |

4 |

Question 59 Explanation:

We have to calculate the difference between the last-in-first-out page replacement policy and the optimal page replacement policy.

First we can consider LIFO (Last In First Out) →

a

Then a

a

Second Optimal Page Replacement Policy →

a

a

a

Total = 10+ 10 +10 = 30. So the difference between LIFO - Optimal = 1

First we can consider LIFO (Last In First Out) →

a

_{1}to a_{10}will result in page faults = 10 page faults,Then a

_{11}will replace a_{10}(last in is a_{10}), a_{12}replace a_{11}and ...till a_{20}= 10 page faults and a_{20}will be top of stack and a_{9}…a_{1}are remained as such. Then a_{1}to a_{9}are already there. So 0 page faults from a_{1}to a_{9}.a

_{10}will replace a_{20}, a_{11}will replace a_{10}and so on = So 11 page faults. So total faults will be 10+10+11 = 31.Second Optimal Page Replacement Policy →

a

_{1}to a_{10}= 10 page faults,a

_{11}will replace a_{10}because among a_{1}to a_{10}, a_{10}will be used later, a_{12}will replace a_{11}and so on = 10 page faults. a_{20}will be top of stack and a_{9}…a_{1}are remained as such.a

_{1}to a_{9}= 0 page fault. a_{10}will replace a_{1}because it will not be used afterwards and so on, a_{10}to a_{19}will have 10 page faults. So no page fault for a_{20}.Total = 10+ 10 +10 = 30. So the difference between LIFO - Optimal = 1

Question 60 |

At most one process can be in the critical section at any time | |

The bounded wait condition is satisﬁed | |

The progress condition is satisﬁed | |

It cannot cause a deadlock |

Question 60 Explanation:

We will check the four options one by one.

Based on the above code option B, C and D are not satisfied. We can see that while (t[j] != 0 && t[j] <= t[i]); because of this condition deadlock is possible when t[j] = = t[i]. Because Progress = = no deadlock as no one process is able to make progress by stopping other process.

Bounded waiting is also not satisfied. In this case both deadlock and bounded waiting to be arising from the same reason as if t[j] = = t[i] is possible then starvation is possible means infinite waiting.

Mutual exclusion is satisfied. All other processes j started before i must have value of t[j]) < t[i] as function pMax() return a integer not smaller than any of its arguments.

So if anyone out of the processes j have positive value will be executing in its critical section as long as the condition t[j] > 0 && t[j] <= t[i] within while will persist. And when this j process comes out of its critical section, it sets t[j] = 0; and next process will be selected in for loop. So, when i process reaches to its critical section none of the processes j which started earlier before process i is in its critical section.

This ensure that only one process is executing its critical section at a time. So, A is the answer.

Based on the above code option B, C and D are not satisfied. We can see that while (t[j] != 0 && t[j] <= t[i]); because of this condition deadlock is possible when t[j] = = t[i]. Because Progress = = no deadlock as no one process is able to make progress by stopping other process.

Bounded waiting is also not satisfied. In this case both deadlock and bounded waiting to be arising from the same reason as if t[j] = = t[i] is possible then starvation is possible means infinite waiting.

Mutual exclusion is satisfied. All other processes j started before i must have value of t[j]) < t[i] as function pMax() return a integer not smaller than any of its arguments.

So if anyone out of the processes j have positive value will be executing in its critical section as long as the condition t[j] > 0 && t[j] <= t[i] within while will persist. And when this j process comes out of its critical section, it sets t[j] = 0; and next process will be selected in for loop. So, when i process reaches to its critical section none of the processes j which started earlier before process i is in its critical section.

This ensure that only one process is executing its critical section at a time. So, A is the answer.

Question 61 |

guarantee serializability and deadlock-freedom | |

guarantee neither serializability nor deadlock-freedom | |

guarantee serializability but not deadlock-freedom | |

guarantee deadlock-freedom but not serializability |

Question 61 Explanation:

Conservative 2PLP:

In conservative 2PL protocol, a transaction has to lock all the items before the transaction begins execution.

Advantages of conservative 2PLP:

• No possibility of deadlock.

• Ensure serializability.

The given scenario (Step1, Step2 and Step3) is conservative 2PLP.

In conservative 2PL protocol, a transaction has to lock all the items before the transaction begins execution.

Advantages of conservative 2PLP:

• No possibility of deadlock.

• Ensure serializability.

The given scenario (Step1, Step2 and Step3) is conservative 2PLP.

Question 62 |

Question 62 Explanation:

Digital signatures are electronic signatures which ensure the integrity, non-repudiation and authenticity of message.

Message digest is a hash value generated by applying a function on it. Message digest is encrypted using private key of sender, so it can only be decrypted by public key of sender.

This ensures that the message was sent by the known sender. Message digest is sent with the original message to the receiving end, where hash function is used on the original message and the value generated by that is matched with the message digest.

This ensures the integrity and thus, that the message was not altered. Digital signature uses private key of the sender to sign message digest.

Message digest is a hash value generated by applying a function on it. Message digest is encrypted using private key of sender, so it can only be decrypted by public key of sender.

This ensures that the message was sent by the known sender. Message digest is sent with the original message to the receiving end, where hash function is used on the original message and the value generated by that is matched with the message digest.

This ensures the integrity and thus, that the message was not altered. Digital signature uses private key of the sender to sign message digest.

Question 63 |

13 | |

14 | |

15 | |

16 |

Question 63 Explanation:

Size of Datagram (L) = 1000 bytes

MTU = 100 bytes

Size of IP header = 20 bytes

Size of Data that can be transmitted in one fragment (payload) = 100 – 20 = 80 bytes

Size of Data to be transmitted = Size of Datagram – size of header = 1000 – 20 = 980 bytes

No. of fragments required = ⌈980/80⌉ = 13

Question 64 |

For a host machine that uses the token bucket algorithm for congestion control, the token bucket has a capacity of 1 megabyte and the maximum output rate is 20 megabytes per second. Tokens arrive at a rate to sustain output at a rate of 10 megabytes per second. The token bucket is currently full and the machine needs to send 12 megabytes of data. The minimum time required to transmit the data is seconds _________.

1.1 sec | |

1.2 sec | |

1.3 sec | |

1.4 sec |

Question 64 Explanation:

According to the token bucket algorithm, the minimum time required sending 1 MB of data or the maximum rate of data transmission is

given by: S = C / (M - P)

Where,

M = Maximum output rate, C = capacity of the bucket, P = Rate of arrival of a token,

Given, M=20 Mb, C=1Mbps, P=10 Mbps

Therefore, S= 1 Mb / (20-10) Mbps = 1/10 = 0.1 sec

Since, the bucket is initially full, it already has 1 Mb to transmit so it will be transmitted instantly. So, we are left with only (12 – 1) Mb, i.e. 11 Mb of data to be transmitted.

Therefore, time required to send the 11 MB will be 11 * 0.1 = 1.1 sec

given by: S = C / (M - P)

Where,

M = Maximum output rate, C = capacity of the bucket, P = Rate of arrival of a token,

Given, M=20 Mb, C=1Mbps, P=10 Mbps

Therefore, S= 1 Mb / (20-10) Mbps = 1/10 = 0.1 sec

Since, the bucket is initially full, it already has 1 Mb to transmit so it will be transmitted instantly. So, we are left with only (12 – 1) Mb, i.e. 11 Mb of data to be transmitted.

Therefore, time required to send the 11 MB will be 11 * 0.1 = 1.1 sec

Question 65 |

2500 | |

2501 | |

2502 | |

2503 |

Question 65 Explanation:

Given,

Frame size (L) =1000 bytes

Sender side bandwidth (B

Acknowledgement size (L

Receiver side bandwidth (B

Propagation delay (T

By formula:

Transmission delay (T

Acknowledge delay (T

Total cycle time = T

Efficiency (η) = T

Throughput = Efficiency (η) * Bandwidth (B

Frame size (L) =1000 bytes

Sender side bandwidth (B

_{S}) = 80 kbps = 10 * 10^{3 }bytes/secAcknowledgement size (L

_{A}) =100 bytesReceiver side bandwidth (B

_{R}) = 8 kbps = 1 * 10^{3}bytes/secPropagation delay (T

_{p}) =100 msBy formula:

Transmission delay (T

_{t}) = L/B_{S}= 1000 bytes / 10 * 10^{3}bytes/sec = 100 msAcknowledge delay (T

_{ack}) = L_{A}/ B_{R}= 100 bytes / 1 * 10^{3}bytes/sec = 100 msTotal cycle time = T

_{t}+ 2 * T_{p}+ T_{ack}= 100 ms + 2 * 100 ms + 100 ms = 400 msEfficiency (η) = T

_{t}/ Total cycle time = 100 ms / 400 ms = 1 / 4 = 0.25Throughput = Efficiency (η) * Bandwidth (B

_{S}) = 0.25 * 10 *10^{3}bytes/s = 2500 bytes/second
There are 65 questions to complete.