In Dijkstra's algorithm, what condition must be met for a vertex to be added to the set of visited vertices?
-
It must have the smallest edge weight
-
It must be the last vertex processed
-
It must be connected to the source
-
It must have the highest degree