Graph Search on Data Structure and Algorithms related Questions and Answers - Page 2

Question 11 : Regarding implementation of Breadth First Search using queues, what is the maximum distance between two nodes present in the queue? (considering each edge length 1)
1. Can be anything
2. 0
3. At most 1
4. Insufficient Information
View Answer   Discuss with Members

Question 15 : Which of the following data structure is used to implement BFS?
1. linked list
2. tree
3. stack
4. queue
5.
View Answer   Discuss with Members

Question 16 : What is the space complexity of standard DFS(V: no. of vertices E: no. of edges)?
1. O(V+E)
2. O(V)
3. O(E)
4. O(V*E)
5.
View Answer   Discuss with Members

Question 17 : What will be the time complexity of the iterative depth first traversal code(V=no. of vertices E=no.of edges)?
1. O(V+E)
2. O(V)
3. O(E)
4. O(V*E)
5.
View Answer   Discuss with Members

Question 18 : Which of the following is a possible result of depth first traversal of the given graph(consider 1 to be source element)? mcq on data structures algorithms
1. 1 2 3 4 5
2. 1 2 3 1 4 5
3. 1 4 5 3 2
4. 1 4 5 1 2 3
5.
View Answer   Discuss with Members

Question 19 : What will be the result of depth first traversal in the following tree?mcq on data structures algorithms
1. 4 2 5 1 3
2. 1 2 4 5 3
3. 4 5 2 3 1
4. 1 2 3 4 5
5.
View Answer   Discuss with Members

Question 20 : Which of the following traversal in a binary tree is similar to depth first traversal?
1. level order
2. post order
3. pre order
4. in order
5.
View Answer   Discuss with Members


View 11 - 20 of 61 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