Nội dung text K-2415 (Paper-II) (Computer Science and Applications).pdf
Total Number of Pages : 8 Paper II 4 K-2415 18. From the following statements : 1) A superkey SK defines a uniqueness constraint that no two distinct tuples in any state r of R can have the same value for SK. 2) A relation schema may have more than one key. In such a case, each of the keys is called a candidate key. 3) A database state that does not obey all the integrity constraints is called an invalid state. Which one of the following is correct ? (A) All statements are true (B) Statements 1) and 2) are true, but statement 3) is false (C) Statements 1) and 3) are true, but statement 2) is false (D) Statements 2) and 3) are true, but 1) is false 19. Note the following statements : 1) The insert operation can violate entity integrity constraint or referential integrity constraint. 2) The delete operation can violate only referential integrity. 3) Updating an attribute that is neither part of a primary key nor a foreign key usually causes no problems. Which one of the following is correct about the statements ? (A) All statements are true (B) Statements 1) and 2) are true, but statement 3) is false (C) Statements, 2) and 3) are true, but statement 1) is false (D) Statements 1) and 3) are true, but statement 2) is false 20. ‘A’ in the ACID property of the Database Management System stands for (A) Accountability (B) Allowability (C) Accessibility (D) Atomicity 21. In a 2-dimentional matrix A, let m be the number of rows, n be the number of columns, ws be the word-size of the data item, lower bound of both row and column be 1 and let BA be the base-address of the matrix. If the matrix were to be stored using row-major representation, the memory location of the element A(i, j) can be found using the formula (A) BA + [((m – 1) * i) + j] * ws (B) BA + [(m * i) + (j – 1)] * ws (C) BA + [(n * (i – 1)) + j] * ws (D) BA + [(n * (i – 1)) +(j – 1)] * ws 22. In a Binary Tree, if the inorder and preorder traversing result in the sequence 5, 4, 6, 7, 8, 3 and 7, 4, 5, 6, 8, 3 respectively, the post-order traversing sequence is (A) 5, 6, 4, 8, 3, 7 (B) 5, 6, 4, 3, 8, 7 (C) 5, 6, 4, 7, 3, 8 (D) 5, 6, 7, 4, 3, 8 23. The Quick sort algorithm : 1) Worst case complexity is O(n2 ) 2) Average case complexity is O(n log2 n) 3) Performs badly when input elements are given in sorted order 4) Pivot element always divides the elements into two equal sized sub-arrays Which of the following option are correct ? (A) Statements 1), 2) and 4) are true, but statement 3) is false (B) Statements 1), 2) and 3) are true, but statement 4) is false (C) Statements 1) and 2) are true, but statements 3) and 4) are false (D) All statements are true