• recategorized by
1,238 views
3 3 votes
Which of the following are true:-

1. DFS continues to visited first unvisited successor of each node as long as possible.

2. Certain nodes are pushed into the stack.

3. DFS first visits all the immediate successors of a node before moving to their successors

4. Certain nodes are pushed into the stack for nore than once.

The answer is 1,2,4.

But I think it should be 1,4.

As.

1. True -- It is DFS characteristic.

2. Doubt ful because in Recursive or iterative all nodes are pushed into the stack.

3. False -- this happens in BFS not in DFS.

4. True -- Iterative DFS.

Please log in or register to answer this question.

Position:
Show:

Related questions

2 2 votes
0 0 answers
2.5k
2.5k views
Shubhanshu asked Oct 18, 2017
2,537 views
I have seen these following question:-Number of Vertices pushed more than once.https://gateoverflow.in/5296/number-of-vs-that-are-pushed-more-than-once-in-a-dfshttps://ga...
1 1 vote
1 1 answer
1.8k
1.8k views
Shubham Kumar Gupta asked Dec 3, 2017
1,767 views
DFS Graph Traversal:Starting vertex $=\mathrm{V}_{6}$Identify valid DFS.$6,8,7,5,4,2,1$$6,3,1,2,4,5,8,7$$6,3,7,8,5,2,4,1$$6,8,5,4,2,1,7$
0 0 votes
1 1 answer
808
808 views
Shivam Kasat asked Dec 9, 2018
808 views
there are multiple algorithm of DFS available and i cant figure out which one to follow for solving question asking for the nodes which aren’t pushed into the stack or th...
0 0 votes
0 0 answers
870
870 views
iarnav asked May 13, 2018
870 views
I know, Kosaraju algorithm and there's one other algorithm which involves reversing of G and using DFS, but two times, but there's some algorithm which uses DFS only time...