Dijkstra's algorithm : graph Shortest Path implementation using java
Input Format The first line contains T, denoting the number of test cases. First line of each test case has two integers N, denoting the number of nodes in the graph and M, denoting the number of edges in the graph. The next M lines each consist of three space-separated integers x,y,r , where x and y denote the two nodes between which the undirected edge exists, r denotes the length of edge between these corresponding nodes. The last line has an integer , S denoting the starting position. Example: 1 4 4 1 2 24 1 4 20 3 1 3 4 3 12 1