Dijkstra's algorithm is a widely used algorithm for finding the shortest path between nodes in a graph, particularly for graphs with non-negative edge weights. It works by selecting the node with the smallest tentative distance and exploring its neighbors, updating their distances iteratively.
- It detects cycles in a directed graph (B) refers to cycle detection algorithms, such as Depth First Search (DFS), not Dijkstra’s algorithm.
- It computes the minimum spanning tree (C) refers to algorithms like Kruskal’s or Prim’s algorithm, not Dijkstra’s.
- It performs topological sorting (D) is a task related to directed acyclic graphs (DAGs) and is typically solved using algorithms like Kahn’s algorithm, not Dijkstra’s.
Therefore, the correct answer is (A), as Dijkstra’s algorithm finds the shortest path in a weighted graph with non-negative weights.