Miscellaneous on Data Structure and Algorithms related Questions and Answers - Page 3

Question 22 : Co-ordinate compression reduces the number of squares in a graph.
1. true
2. false
3.
4.
View Answer   Discuss with Members

Question 23 : What is the worst case time complexity of quickselect?
1. O(n log n)
2. O(n2)
3. O(n)
4. O(log n)
View Answer   Discuss with Members

Question 24 : What is the best case time complexity of quickselect?
1. O(n log n)
2. O(n2)
3. O(n)
4. O(log n)
View Answer   Discuss with Members

Question 25 : A man wants to go different places in the world. He has listed them down all. But there are some places where he wants to visit before some other places. What application of graph can he use to determine that?
1. Depth First Search
2. Breadth First Search
3. Topological Sorting
4. Dijkstra's Shortest path algorithm
View Answer   Discuss with Members

Question 26 : What will be the worst case time complexity of code to find sum in given query range (l,r) in an array of size n with q number of such queries?
1. O(n)
2. O(q)
3. O(n*q)
4. O(n+q)
View Answer   Discuss with Members

Question 28 : Square root decomposition technique is only applicable when the number of indices in an array is a perfect square.
1. true
2. false
3.
4.
View Answer   Discuss with Members

Question 29 : What will be the output if quickselect algorithm is applied to the array arr={1,5,4,3,7} with k given as 4?
1. 1
2. 3
3. 4
4. 5
View Answer   Discuss with Members

Question 30 : Topological sort is equivalent to which of the traversals in trees?
1. Pre-order traversal
2. Post-order traversal
3. In-order traversal
4. Level-order traversal
View Answer   Discuss with Members


View 21 - 30 of 49 Questions

* Be the First to Post a Comment.

Submit comment :


Captcha Image
Reload

Ask Question

Captcha Image
Reload

Note : Name and Email never shown.





Subscribe


Become a part of EducationForever. Subscribe to our FREE Newsletter