Teaching HPSC Lecturer (Technical) Mock Test 2024 Algorithms Graphs/Spanning Tree and Shortest Paths Shortest Paths
Which of the following is true about shortest path algorithm?
i. The data structure Queue is used to implement Dijkstra’s shortest path algorithm to run in linear time.
ii. Bellman-Ford algorithm can work on a weighted graph in which edges can have negative weights.
iii. Bellman-Ford algorithm can be applied to a wider class of input than Dijkstra.
1
i
2
ii
3
iii
4
ii and iii
5
Question Not Attempted