Ejemplo n.º 1
0
 private static void ReadEdges(int m, Graph graph)
 {
     for (int i = 0; i < m; i++)
     {
         string[] edgeArguments = ReadConsoleLine();
         int from = int.Parse(edgeArguments[0]);
         int to = int.Parse(edgeArguments[1]);
         int distance = int.Parse(edgeArguments[2]);
         graph.AddEdge(from, to, distance);
     }
 }