Both can be used to find the shortest path from single source. BFS runs in O(E+V), while Dijkstra\'s runs in O((V+E)*log(V)).
O(E+V)
O((V+E)*log(V))
Also, I\'ve s
From implementation perspective, the Dijkstra's algorithm could be implemented exactly like a BFS by swapping the queue with a priority queue.
queue
priority queue
Source