• retagged by
1,545 views
0 0 votes
can anyone explain how dijkstras will behave as BFS whwn a graph is unweighted?

 

2 Answers

0 0 votes
In an unweighted graph,priority queue will behave like a simple queue (as all the connected edges is represented as 1) with FIFO policy.At first, the first frontier will be pushed into the queue & explored(nodes which are just a single edge away from the source node) and then the second frontier,and so on.This behavior resembles that of BFS.
Position:
Show:

Related questions

0 0 votes
2 answers 2 answers
3.5k
3.5k views
noob_coder asked Mar 10, 2019
3,526 views
Suppose that you are running Dijkstra’s algorithm on the edge-weighted diagram below, starting from vertex A. The Table gives ‘Distance’ and ‘Parent’ entry of each verte...
1 1 vote
1 1 answer
5.2k
5.2k views
Pankaj Joshi asked Jan 20, 2017
5,219 views
Which of the following statements is true?Adding a constant to every edge weight in a directed graph can change the set of edges that belongs to minimum cost spanning tre...
18 18 votes
1 1 answer
3.2k
3.2k views
User007 asked Sep 24, 2016
3,155 views
For the graph given below Dijkstra’s algorithm does not provide correct shortest path tree.Suppose a new graph that is different only in weight between Q to S is created....