Programming Question-5: Dijkstra's shortest-path - Implementation of the algorithm