BARC Computer Science and Information Technology Previous Year Question Solved
1.) The worst-case time complexity of Quick Sort is:
Answer: O(n^2)
Explanation: Quicksort is based on the divide and conquers paradigm. Quicksort expected average running time is O(nlogn)
2.) In C programming operator '&' is used to represent:
- Logical AND
- Bitwise AND
- Logical OR
- Bitwise OR
Answer: Bitwise AND
Explanation: logical AND (&&), bitwise AND (&), Logical OR (||), Bitwise OR(|)
3.) When a static variable is initialized:
Answer: First time when a loop is executed.
Explanation: Static variables only execute once.
4.) What is the maximum height of the AVL tree with 7 nodes? Assume that height of the tree with a single node is 0.
5.) Data structure used in the recursive algorithm is:
Comments
Post a Comment