import java.util.Scanner;
import java.io.*;
public class Assignment14B
{
	public static void main (String[] args)
	{
			File textFile= new File("U:\\numbers.dat");
			FileReader in;
			BufferedReader readFile;
			String score;
			double average,total=0;
			int number=0,highest=0,lowest=100;			
	
			try
			{             in = new FileReader(textFile);
				readFile= new BufferedReader(in);
				while((score=readFile.readLine())!=null)
				{    
					number=Integer.parseInt (score);
					if (number>highest)
						highest=number;
					if (number<lowest)
						lowest=number;
					System.out.println(score);
					
				}
			    
				System.out.println("Highest= "+highest);
				System.out.println("Lowest= "+lowest);
				readFile.close();
				in.close();	
			}
			catch (FileNotFoundException e )
			{             System.out.println(" File does not exist");
				System.err.println("FileNotFoundException :"+ e.getMessage());
			}
			catch (IOException e)
			{             System.out.println(" Problem reading file");
				System.err.println("IOException :"+ e.getMessage());
			}
	}
}
