InterviewSolution
Saved Bookmarks
This section includes InterviewSolutions, each offering curated multiple-choice questions to sharpen your knowledge and support exam preparation. Choose a topic below to get started.
| 1. |
Breadth First Search (BFS) is started on a binary tree beginning from the root vertex. There is a vertex t at a distance four from the root. If t is the n-th vertex in this BFS traversal, then the maximum possible value of n is ________[This Question was originally a Fill-in-the-blanks Question](A) 15(B) 16(C) 31(D) 32 |
| Answer» None | |
| 2. |
Match the following:(P) Lexical analysis (i) Leftmost derivation(Q) Top down parsing (ii) Type checking(R) Semantic analysis (iii) Regular expressions(S) Runtime environments (iv) Activation records(A) A(B) B(C) C(D) D |
| Answer» | |
| 3. |
Consider the following types of languages:L1 Regular,L2: Context-free,L3: Recursive,L4: Recursively enumerable. Which of the following is/are TRUE?I. L3' U L4 is recursively enumerableII. L2 U L3 is recursiveIII. L1* U L2 is context-freeIV. L1 U L2' is context-free (A) I only(B) I and III only(C) I and IV only(D) I, II and III only |
| Answer» | |
| 4. |
The value printed by the following program isvoid f(int* p, int m){m = m + 5;*p = *p + m;return;}void main(){int i=5, j=10;f(&i, j);printf("%d", i+j);}(A) 10(B) 20(C) 30(D) 40 |
| Answer» None | |
| 5. |
Consider the following statements:P: L1 is regularQ: L2 is regularWhich one of the following is TRUE?(A) Both P and Q are true(B) P is true and Q is false(C) P is false and Q is true(D) Both P and Q are false |
| Answer» | |
| 6. |
The number of states in the minimum sized DFA that accepts the language defined by the regular expression (0+1)*(0+1)(0+1)* is __________________[Note that this question was originally asked as Fill-in-the-Blanks type](A) 2(B) 3(C) 4(D) 5 |
| Answer» | |
| 7. |
Identify the correct sequence in which the following packets are transmitted on the network by a host when a browser requests a webpage from a remote server, assuming that the host has just been restarted.(A) HTTP GET request, DNS query, TCP SYN(B) DNS query, HTTP GET request, TCP SYN(C) DNS query, TCP SYN, HTTP GET request(D) TCP SYN, DNS query, HTTP GET request |
| Answer» | |
| 8. |
B+ Trees are considered BALANCED because(A) the lengths of the paths from the root to all leaf nodes are all equal.(B) the lengths of the paths from the root to all leaf nodes differ from each other by at most 1.(C) the number of children of any two non-leaf sibling nodes differ by at most 1.(D) the number of records in any two leaf nodes differ by at most 1. |
| Answer» | |
| 9. |
Suppose a database schedule S involves transactions T1, ….Tn. Construct the precedence graph of S with vertices representing the transactions and edges representing the conflicts. If S is serializable, which one of the following orderings of the vertices of the precedence graph is guaranteed to yield a serial schedule?(A) Topological order(B) Depth-first order(C) Breadth-first order(D) Ascending order of transaction indices |
| Answer» | |
| 10. |
Consider the following database schedule with two transactions, T1 and T2.S = r2(X); r1(X); r2(Y); w1(X); r1(Y); w2(X); a1; a2;where ri(Z) denotes a read operation by transaction Ti on a variable Z, wi(Z) denotes a write operation by Ti on a variable Z and ai denotes an abort by transaction Ti .Which one of the following statements about the above schedule is TRUE?(A) S is non-recoverable(B) S is recoverable, but has a cascading abort(C) S does not have a cascading abort(D) S is strict |
| Answer» | |
| 11. |
The number of ways in which the numbers 1, 2, 3, 4, 5, 6, 7 can be inserted in an empty binary search tree, such that the resulting tree has height 6, is _____________Note: The height of a tree with a single node is 0.[This question was originally a Fill-in-the-Blanks question](A) 2(B) 4(C) 64(D) 32 |
| Answer» None | |