A) 24
B) 25
C) 26
D) 27
Answer : (C)
2 The Boolean function x, y, + xy + x, y
A) x, + y,
B) x + y
C) x + y,
D) x, + y
Answer : (D)
3 In an MxN matrix such that all non-zero entries are covered in a rows and b columns. Then the maximum number of non-zero entries, such that no two are on the same row or column, is
A) £ a + b
B) £ max {a, b}
C) £ min {M-a, N-b}
D) £ min {a, b}
Answer : (A)
4 The relation scheme Student Performance (name, courseNo, rollNo, grade) has the following functional dependencies:
A) name, courseNo -> grade
B) rollNo, courseNo -> grade
C) name -> rollNo
D) rollNo -> name
The highest normal form of this relation scheme is
Answer : (A)
5 The minimum number of page frames that must be allocated to a running process in a virtual memory environment is determined by
A) the instruction set architecture
B) page size
C) physical memory size
D) number of processes in memory
Answer : (D)
6 Let G be a simple graph with 20 vertices and 100 edges. The size of the minimum vertex cover of G is 8. Then, the size of the maximum independent set of G is
A) 12
B) 8
C) Less than 8
D) More than 12
Answer : (A)
7 What does the following algorithm approximate? (Assume m > 1, Î > 0).
x = m;
y-i;
while (x - y > Î)
{ x = (x + y) / 2 ;
y = m/x ;
}
print (x) ;
A) log m
B) m2
C) m1/2
D) m1/3
Answer : (C)
8 Consider the following C program
main ()
{ int x, y, m, n ;
scanf ("%d %d", &x, &y);
/ * Assume x > 0 and y > 0 * /
m = x; n = y ;
while ( m ! = n)
{ if (m > n)
m = m — n;
else
n = n - m ; }
printf("%d",n); }
The program computes
A) x + y, using repeated subtraction
B) x mod y using repeated subtraction
C) the greatest common divisor of x and y
D) the least common multiple of x and y
Answer : (C)
9 The best data structure to check whether an arithmetic expression has balanced parentheses is a
A) queue
B) stack
C) tree
D) list
Answer : (B)
10 A Priority-Queue is implemented as a Max-Heap. Initially, it has 5 elements. The level-order traversal of the heap is given below: 10, 8,5,3,2 Two new elements 1 and 7 are inserted in the heap in that order. The level-order traversal of the heap after the insertion of the elements is
A) 10,8,7,5,3,2,1
B) 10,8,7,2,3,1,5
C) 10,8,7,1,2,3,5
D) 10,8,7,3,2,1,5
Answer : (D)
11 An organization has a class B network and wishes to form subnets for 64 departments. The subnet mask would be
A) 255.255.0.0
B) 255.255.64.0
C) 255.255.128.0
D) 255.255.252.0
Answer : (D)
12 Suppose the round trip propagation delay for a 10 Mbps Ethernet having 48-bit jamming signal is 46.4 ms. The minimum frame size is:
A) 94
B) 416
C) 464
D) 512
Answer : (C)
13 The following numbers are inserted into an empty binary search tree in the given order: 10, 1, 3, 5, 15, 12, 16. What is the height of the binary search tree (the height is the maximum distance of a leaf node from the root)?
A) 2
B) 3
C) 4
D) 6
Answer : (B)
14 Consider the following C function:
int f (int n)
{ static int i = 1;
if (n >= 5) return n;
n = n + i;
i ++;
return f (n);
}
The value returned by f(1) is
A) 5
B) 6
C) 7
D) 8
Answer : (C)
15 The minimum number of page frames that must be allocated to a running process in a virtual memory environment is determined by
A) the instruction set architecture
B) page size
C) physical memory size
D) number of processes in memory
Answer : (D)
1 The address resolution protocol (ARP) is used for
A) Finding the IP address from the DNS
B) Finding the IP address of the default gateway
C) Finding the IP address that corresponds to a MAC address
D) Finding the MAC address that corresponds to an IP address
Answer : (D)
2 Consider the following relation schema pertaining to a students database:
Student (rollno, name, address)
Enroll (rollno, courseno, coursename)
where the primary keys are shown underlined. The number of tuples in the Student and Enroll tables are 120 and 8 respectively. What are the maximum and minimum number of tuples that can be present in (Student * Enroll), where ‘*’denotes natural join?
A) 8, 8
B) 120, 8
C) 960, 8
D) 960, 120
Answer : (C)
3 Consider a direct mapped cache of size 32 KB with block size 32 bytes. The CPU generates 32 bit addresses. The number of bits needed for cache indexing and the number of tag bits are respectively
A) 10, 17
B) 10, 22
C) 15, 17
D) 5, 17
Answer : (A)
4 The goal of structured programming is to
A) have well indented programs
B) be able to infer the flow of control from the compiled code
C) be able to infer the flow of control from the program text
D) avoid the use of GOTO statements
Answer : (C)
5 The tightest lower bound on the number of comparisons, in the worst ease, for comparison-based sorting is of the order of
A) n
B) n 2
C) n log n
D) n log2 n
Answer : (B)
6 Let G be a simple graph with 20 vertices and 100 edges. The size of the minimum vertex cover of G is 8. Then, the size of the maximum independent set of G is
A) 12
B) 8
C) Less than 8
D) More than 12
Answer : (A)
7 WA and B are the only two stations on an Ethernet. Each has a steady queue of frames to send. Both A and B attempt to transmit a frame, collide, and A wins the first backoff race. At the end of this successful transmission by A, both A and B attempt to transmit and collide. The probability that A wins the second backoff race is
A) 0.5
B) 0.625
C) 0.75
D) 1.0
Answer : (A)
8 Let A be a sequence of 8 distinct integers sorted in ascending order. How many distinct pairs of sequences, B and C are there such that (i) each is sorted in ascending order, (ii) B has 5 and C has 3 elements, and (iii) the result of merging B and C gives A?
A) 2
B) 30
C) 56
D) 256
Answer : (D)
9 In a network of LANs connected by bridges, packets are sent from one LAN to another through intermediate bridges. Since more than one path may exist between two LANs, packets may have to be routed through multiple bridges.
Why is the spanning tree algorithm used for bridge-routing?
A) For shortest path routing between LANs
B) For avoiding loops in the routing paths
C) For fault tolerance
D) For minimizing collisions
Answer : (B)
10 A Priority-Queue is implemented as a Max-Heap. Initially, it has 5 elements. The level-order traversal of the heap is given below: 10, 8,5,3,2 Two new elements 1 and 7 are inserted in the heap in that order. The level-order traversal of the heap after the insertion of the elements is
A) 10,8,7,5,3,2,1
B) 10,8,7,2,3,1,5
C) 10,8,7,1,2,3,5
D) 10,8,7,3,2,1,5
Answer : (D)
11 An organization has a class B network and wishes to form subnets for 64 departments. The subnet mask would be
A) 255.255.0.0
B) 255.255.64.0
C) 255.255.128.0
D) 255.255.252.0
Answer : (D)
12 Suppose the round trip propagation delay for a 10 Mbps Ethernet having 48-bit jamming signal is 46.4 ms. The minimum frame size is:
A) 94
B) 416
C) 464
D) 512
Answer : (C)
1 The problems 3-SAT and 2-SAT are
A) both in P
B) both NP-complete
C) NP-complete and in P respectively
D) undecidable and NP-complete respectively
Answer : (C)
2 Consider the following relation schema pertaining to a students database:
Student (rollno, name, address)
Enroll (rollno, courseno, coursename)
where the primary keys are shown underlined. The number of tuples in the Student and Enroll tables are 120 and 8 respectively. What are the maximum and minimum number of tuples that can be present in (Student * Enroll), where ‘*’denotes natural join?
A) 8, 8
B) 120, 8
C) 960, 8
D) 960, 120
Answer : (C)
3 Consider a relation scheme R = (A, B, C, D, E, H) on which the following functional dependencies hold : (A -> B, BC -> D, E -> C, D -> A). What are the candidate keys of R?
A) AE, BE
B) AE, BE, DE
C) AEH, BEH, BCH
D) AEH, BEH, DEH
Answer : (D)
4 The goal of structured programming is to
A) have well indented programs
B) be able to infer the flow of control from the compiled code
C) be able to infer the flow of control from the program text
D) avoid the use of GOTO statements
Answer : (C)
5 The tightest lower bound on the number of comparisons, in the worst ease, for comparison-based sorting is of the order of
A) n
B) n 2
C) n log n
D) n log2 n
Answer : (B)
6 A circuit outputs a digit in the form of 4 bits. 0 is represented by 0000,1 by 0001,..., 9 by 1001. A combinational circuit is to be designed which takes these 4 bits as input and outputs 1 if the digit ³ 5, and 0 otherwise. If only AND, OR and NOT gates may be used, what is the minimum number of gates required
A) 2
B) 3
C) 4
D) 5
Answer : (C)
7 WA and B are the only two stations on an Ethernet. Each has a steady queue of frames to send. Both A and B attempt to transmit a frame, collide, and A wins the first backoff race. At the end of this successful transmission by A, both A and B attempt to transmit and collide. The probability that A wins the second backoff race is
A) 0.5
B) 0.625
C) 0.75
D) 1.0
Answer : (A)
8 If 73x (in base-x number system) is equal to 54y (in base-y number system), the possible values of x and y are
A) 8, 16
B) 10, 12
C) 9, 13
D) 8, 11
Answer : (D)
9 In a packet switching network, packets are routed from source to destination along a single path having two intermediate nodes. If the message size is 24 bytes and each packet contains a header of 3 bytes, then the optimum packet size is
A) 4
B) 6
C) 7
D) 9
Answer : (D)
10 A Priority-Queue is implemented as a Max-Heap. Initially, it has 5 elements. The level-order traversal of the heap is given below: 10, 8,5,3,2 Two new elements 1 and 7 are inserted in the heap in that order. The level-order traversal of the heap after the insertion of the elements is
A) 10,8,7,5,3,2,1
B) 10,8,7,2,3,1,5
C) 10,8,7,1,2,3,5
D) 10,8,7,3,2,1,5
Answer : (D)
11 Consider an operating system capable of loading and executing a single sequential user process at a time. The disk head scheduling algorithm used is First Come First Served (FCFS). If FCFS is replaced by Shortest Seek Time First (SSTF), claimed by the vendor to give 50% better benchmark results, what is the expected improvement in the I/O performance of user programs ?
A) 50%
B) 40%
C) 25%br> D) 0%
Answer : (D)
12 How many distinct binary search trees can be created out of 4 distinct keys?
A) 5
B) 14
C) 24
D) 42
Answer : (B)
Q-1 Select the one true statement. A) Every binary tree is either complete or full.
B) Every complete binary tree is also a full binary tree.
C) Every full binary tree is also a complete binary tree
D) No binary tree is both complete and full.
Q-2 Which data structure has the fastest insertion procedure? A) Binary search tree
B) Ordered array
C) Heap
D) Unordered linked list
E) Ordered linked list
Q-3 What are the complexities of the insert, remove and search methods of a binary search tree in the worst case? A) insert is O(n), remove is O(n), search is O(n)
B) insert is O(log n), remove is O(log n), search is O(n)
C) insert is O(log n), remove is O(log n), search is O(log n)
D) insert is O(log n), remove is O(log n), search is O(1)
E) These methods can't be defined on a binary search tree Q-4 This Ethernet frame type is characterized by its use of the code AA in the SAP fields. A) Ethernet II
B) Ethernet RAW
C) Ethernet 802.2
D) Ethernet SNAP Q-5 Which of the following are examples of routed protocols? (Choose all that apply) A) IP
B) IPX
C) RIP
D) OSPF
E) AppleTalk Q-6 If switches are used to replace hubs on a network, which of the following statements is true? A) The number of broadcast domains will decrease
B) The number of collision domains will increase
C) The number of collision domains will decrease
D) The number of broadcast domains will be zero
Q-7 Full duplex Ethernet communication is only possible when:
A. Systems are connected to same LAN segments
B. Systems are connected to a bridged ports
C. Systems are connected to their own switch port
D. Systems are running over a fiber optic connection
A ) DDL and DQL
B ) DDL , DML and DQL
C ) DDL,DML,DQL and DCL
D ) None of these
Q-9 Which of the following applications may use a stack?
A) A parentheses balancing program.
B) Keeping track of local variables at run time.
C) Syntax analyzer for a compiler.
D) All of the above
Q -10 Consider the implementation of the Stack using a partially-filled array. What goes wrong if we try to store the top of the Stack at location [0] and the bottom of the Stack at the last used position of the array?
A) Both peek and pop would require linear time.
B) Both push and pop would require linear time.
C) The Stack could not be used to check balanced parentheses.
D) The Stack could not be used to evaluate postfix expressions.
1 | Consider the following program segment for a hypothetical CPU having three user registers Rl, R2 and R3.
Let the clock cycles required for various operations be as follows: | ||||||||||||||||||
Options |
| ||||||||||||||||||
Correct Answer | B | ||||||||||||||||||
2 | The order of an internal node in a B+ tree index is the maximum number of children it can have. Suppose that a child pointer takes 6 bytes, the search field value takes 14 bytes, and the block size is 512 bytes. What is the order of the internal node? | ||||||||||||||||||
Options |
| ||||||||||||||||||
Correct Answer | C | ||||||||||||||||||
3 | The Boolean function x , y , + xy + x , y | ||||||||||||||||||
Options |
| ||||||||||||||||||
Correct Answer | D | ||||||||||||||||||
4 | In an MxN matrix such that all non-zero entries are covered in a rows and b columns. Then the maximum number of non-zero entries, such that no two are on the same row or column, is | ||||||||||||||||||
Options |
| ||||||||||||||||||
Correct Answer | A | ||||||||||||||||||
5 | The relation scheme Student Performance (name, courseNo, rollNo, grade) has the following functional dependencies: name, courseNo ® grade rollNo, courseNo ® grade name ® rollNo rollNo ® name The highest normal form of this relation scheme is | ||||||||||||||||||
Correct Answer | A | ||||||||||||||||||
6 | The minimum number of page frames that must be allocated to a running process in a virtual memory environment is determined by | ||||||||||||||||||
Options |
| ||||||||||||||||||
Correct Answer | D | ||||||||||||||||||
7 | Consider the following program segment for a hypothetical CPU having three user registers Rl, R2 and R3.
Consider that the memory is byte addressable with size 32 bits, and the program has been loaded starting from memory location 1000 (decimal). If an interrupt occurs while the CPU has been halted after executing the HALT instruction, the return address (in decimal) saved in the stack will be | ||||||||||||||||||
Options |
| ||||||||||||||||||
Correct Answer | A | ||||||||||||||||||
8 | Let G be a simple graph with 20 vertices and 100 edges. The size of the minimum vertex cover of G is 8. Then, the size of the maximum independent set of G is | ||||||||||||||||||
Options |
| ||||||||||||||||||
Correct Answer | A | ||||||||||||||||||
9 | What does the following algorithm approximate? (Assume m > 1, Î > 0). x = m; y-i; while (x - y > Î ) { x = (x + y) / 2 ; y = m/x ; } print (x) ; | ||||||||||||||||||
Options |
| ||||||||||||||||||
Correct Answer | C | ||||||||||||||||||
10 | Consider the following C program main () { int x, y, m, n ; scanf ("%d %d", &x, &y); / * Assume x > 0 and y > 0 * / m = x; n = y ; while ( m ! = n) { if (m > n) m = m — n; else n = n - m ; } printf("%d",n); } The program computes | ||||||||||||||||||
Options |
| ||||||||||||||||||
Correct Answer | C | ||||||||||||||||||
11 | The best data structure to check whether an arithmetic expression has balanced parentheses is a | ||||||||||||||||||
Options |
| ||||||||||||||||||
Correct Answer | B | ||||||||||||||||||
12 | A Priority-Queue is implemented as a Max-Heap. Initially, it has 5 elements. The level-order traversal of the heap is given below: 10, 8,5,3,2 Two new elements 1 and 7 are inserted in the heap in that order. The level-order traversal of the heap after the insertion of the elements is | ||||||||||||||||||
Options |
| ||||||||||||||||||
Correct Answer | D | ||||||||||||||||||
13 | Consider the following C program segment The value returned by the function DoSomething when a pointer to the root of a | ||||||||||||||||||
Options |
| ||||||||||||||||||
Correct Answer | D | ||||||||||||||||||
14 | An organization has a class B network and wishes to form subnets for 64 departments. The subnet mask would be | ||||||||||||||||||
Options |
| ||||||||||||||||||
Correct Answer | D | ||||||||||||||||||
15 | Suppose the round trip propagation delay for a 10 Mbps Ethernet having 48-bit jamming signal is 46.4 m s. The minimum frame size is: | ||||||||||||||||||
Options |
| ||||||||||||||||||
Correct Answer | C | ||||||||||||||||||
16 | Consider the following C program segment: char p [ 20]; char * s = "string" ; int length = strlen (s) ; for (i = 0 ; i <> p[ i ] = s [length - i] ; print f ("%s", p) ; | ||||||||||||||||||
Correct Answer | A | ||||||||||||||||||
17 | Consider the grammar S ® (S) | a Let the number of states in SLR(1), LR(1) and LALR(1) parsers for the grammar be n 1 , n 2 and n 3 respectively. The following relationship holds good | ||||||||||||||||||
Options |
| ||||||||||||||||||
Correct Answer | B | ||||||||||||||||||
18 | Consider the following C function: int f (int n) { static int i = 1; if (n >= 5) return n; n = n + i; i ++; return f (n); } The value returned by f(1) is | ||||||||||||||||||
Options |
| ||||||||||||||||||
Correct Answer | C | ||||||||||||||||||
19 | Consider the following code fragment: if (fork ( ) = = 0) {a = a + 5; print f (“%d, %d / n”, a, and a); } else {a - 5; print f (“ %d, %d / n”, a,& a); } Let u, v be the values printed by the parent process, and x, y be the values printed by the child process. Which one of the following is TRUE? | ||||||||||||||||||
Options |
| ||||||||||||||||||
Correct Answer | B | ||||||||||||||||||
20 | The following numbers are inserted into an empty binary search tree in the given order: 10, 1, 3, 5, 15, 12, 16. What is the height of the binary search tree (the height is the maximum distance of a leaf node from the root)? | ||||||||||||||||||
Options |
| ||||||||||||||||||
Correct Answer | B |
1 | Consider the following C function void swap (int a, int b) { int temp ; temp = a ; a = b ; b = temp ; } In order to exchange the values of two variables x and y. | ||||
Options |
| ||||
Your Answer | ( Not Answered ) | ||||
Correct Answer | B | ||||
2 | A 5 stage pipelined CPU has the following sequence of stages: IF - Instruction fetch from instruction memory, RD - Instruction decode and register read, EX - Execute: ALU operation for data and address computation, MA - Data memory access - for write access, the register read at RD stage is used, WB - Register write back. Consider the following sequence of instructions: I 1 : L R0, 1oc1; R0 <= M[1oc1] I 2 : A R0, R0; R0 <= R0 + R0 I 3 : A R2, R0; R2 <= R2 - R0 Let each stage take one clock cycle. What is the number of clock cycles taken to complete the above sequence of instructions starting from the fetch of I 1 ? | ||||
Options |
| ||||
Your Answer | ( Not Answered ) | ||||
Correct Answer | A | ||||
3 | The address resolution protocol (ARP) is used for | ||||
Options |
| ||||
Your Answer | ( Not Answered ) | ||||
Correct Answer | D | ||||
4 | Consider the following relation schema pertaining to a students database: Student ( rollno , name, address) Enroll ( rollno , courseno , coursename) where the primary keys are shown underlined. The number of tuples in the Student and Enroll tables are 120 and 8 respectively. What are the maximum and minimum number of tuples that can be present in (Student * Enroll), where ‘*'denotes natural join? | ||||
Options |
| ||||
Your Answer | ( Not Answered ) | ||||
Correct Answer | C | ||||
5 | Consider a direct mapped cache of size 32 KB with block size 32 bytes. The CPU generates 32 bit addresses. The number of bits needed for cache indexing and the number of tag bits are respectively | ||||
Options |
| ||||
Your Answer | ( Not Answered ) | ||||
Correct Answer | A | ||||
6 | Which one of the following is a key factor for preferring B + -trees to binary search trees for indexing database relations? | ||||
Options |
| ||||
Your Answer | ( Not Answered ) | ||||
Correct Answer | D | ||||
7 | The goal of structured programming is to | ||||
Options |
| ||||
Your Answer | ( Not Answered ) | ||||
Correct Answer | C | ||||
8 | The tightest lower bound on the number of comparisons, in the worst ease, for comparison-based sorting is of the order of | ||||
Options |
| ||||
Your Answer | ( Not Answered ) | ||||
Correct Answer | B | ||||
9 | Consider the following two problems on undirected graphs a: Given G(V, E), does G have an independent set of size |V| -4? b: Given G(V, E), does G have an independent set of size 5? Which one of the following is TRUE? | ||||
Options |
| ||||
Your Answer | ( Not Answered ) | ||||
Correct Answer | C | ||||
10 | Consider the languages L 1 = {ww R | w Î {0, 1}*} L 2 = {w# w R | w Î {0, 1}*}, where # is a special symbol L 3 = {ww | w Î {0, 1}*} Which one of the following is TRUE? | ||||
Options |
| ||||
Your Answer | ( Not Answered ) | ||||
Correct Answer | B | ||||
11 | Let G be a simple graph with 20 vertices and 100 edges. The size of the minimum vertex cover of G is 8. Then, the size of the maximum independent set of G is | ||||
Options |
| ||||
Your Answer | ( Not Answered ) | ||||
Correct Answer | A | ||||
12 | A and B are the only two stations on an Ethernet. Each has a steady queue of frames to send. Both A and B attempt to transmit a frame, collide, and A wins the first backoff race. At the end of this successful transmission by A, both A and B attempt to transmit and collide. The probability that A wins the second backoff race is | ||||
Options |
| ||||
Your Answer | ( Not Answered ) | ||||
Correct Answer | A | ||||
13 | Consider the grammar E ® E + n | E x n | n For a sentence n + n x n, the handles in the right-sentential form of the reduction are | ||||
Options |
| ||||
Your Answer | ( Not Answered ) | ||||
Correct Answer | D | ||||
14 | Consider the grammar with the following translation rules and E as the start symbol. E ® E 1 # T {E.value = E 1 .value * T.value } | T {E.value = T.value } T ® T 1 & F { T.value = T 1 .value + F.value } | F {T.value = F.value} F ® num {F.value = num.value } Compute E. value for the root of the parse tree for the expression: 2 # 3 & 5 # 6 & 4. | ||||
Options |
| ||||
Your Answer | ( Not Answered ) | ||||
Correct Answer | C | ||||
15 | Let A be a sequence of 8 distinct integers sorted in ascending order. How many distinct pairs of sequences, B and C are there such that (i) each is sorted in ascending order, (ii) B has 5 and C has 3 elements, and (iii) the result of merging B and C gives A? | ||||
Options |
| ||||
Your Answer | ( Not Answered ) | ||||
Correct Answer | D | ||||
16 | Which one of the following is true for a CPU having a single interrupt request line and a single interrrupt grant line? | ||||
Options |
| ||||
Your Answer | ( Not Answered ) | ||||
Correct Answer | B | ||||
17 | Consider a relation scheme R = (A, B, C, D, E, H) on which the following functional dependencies hold : (A ® B, BC ® D, E ® C, D ® A). What are the candidate keys of R? | ||||
Options |
| ||||
Your Answer | ( Not Answered ) | ||||
Correct Answer | D | ||||
18 | In a network of LANs connected by bridges, packets are sent from one LAN to another through intermediate bridges. Since more than one path may exist between two LANs, packets may have to be routed through multiple bridges. Why is the spanning tree algorithm used for bridge-routing? | ||||
Options |
| ||||
Your Answer | ( Not Answered ) | ||||
Correct Answer | B | ||||
19 | Suppose T(n) = 2T (n/2) + n, T(0) = T(1) = 1 Which one of the following is FALSE? | ||||
Options |
| ||||
Your Answer | ( Not Answered ) | ||||
Correct Answer | B | ||||
20 | Consider the following C program segment The value returned by the function DoSomething when a pointer to the root of a | ||||
Options |
| ||||
Your Answer | ( Not Answered ) | ||||
Correct Answer | D |
No comments:
Post a Comment