/**
 * CS 409 Spring, 2001
 */

import java.io.*;

public class test
{

	public static void main (String[] args) throws IOException 
	{

		//There are 94549 nodes
		int NUM_NODES = 94549;
		
		//If you want to test with NY data, nodes in ny begins with 51973 and ends with 57983
		int NY_NODE_BEGIN = 51973, NY_NODE_END = 57983;
		
		PrintWriter output = new PrintWriter(new FileWriter("result.txt"));
		
		//constructing a Graph object
		Graph g = new Graph(1, NUM_NODES, "road.dat");

		//write the resulting path into output
		g.Dijkstra("NYITHACA C-W", "PASCRANTON SSW", output);
		
		int n = g.connectedComponent();
		output.println("\n******************************************");
		output.println(n + " connected components in this network.");
				
		output.close();
		
		System.out.println("Press any key to exit...");
		System.in.read();
	}
}
