Loading repovive.com/problems/classics/13
Given a weighted directed graph with vertices and edges, find the shortest distance from vertex to all other vertices.
All edge weights are non-negative. If a vertex is unreachable from vertex , output for that vertex.
For this input, the required output is 0 1 3 4.
For this input, the required output is 0 10 30.
For this input, the required output is 0 5 -1.