public void readFile(String fileName) throws IOException, NumberFormatException{
		FileInputStream in = new FileInputStream(fileName);
		BufferedReader br = new BufferedReader(new InputStreamReader(in));
		
		int src,dest,weigh,lc=0;
		String line;
		String[] strLine;
		while(true){
			line=br.readLine();
			if(line==null){
				break;
			}
			
			strLine= line.split(" ");
			
			if(lc==0){
				n=Integer.parseInt(strLine[0]);
				m=Integer.parseInt(strLine[1]);
				
				// array  declarations
				A= new long[(n+1)][(n+1)][2];
				for(int i=1;i<(n+1);i++){
					for( int j=1;j<(n+1);j++){
						for(int k=0;k<2;k++){
							if(i==j){
								A[i][j][k]=0;
							}else{
							A[i][j][k]=10000;
							}// end else
						}// end k
					}// end j				
				}// end i			
			}else{
				src=Integer.parseInt(strLine[0]);
				dest=Integer.parseInt(strLine[1]);					
				weigh=Integer.parseInt(strLine[2]);
				A[src][dest][0]=weigh;
			}
			lc++;
		}// end while		
		in.close();
	 }// end readFile