{[ promptMessage ]}

Bookmark it

{[ promptMessage ]}

Program5 - import import import import i import java.io...

Info iconThis preview shows pages 1–3. Sign up to view the full content.

View Full Document Right Arrow Icon
import java.io.*; import java.text.*; import java.util.Scanner; import java.lang.*; import java.math.*; i // Jeremy Debruce // 11/6/2007 //Program 5 / public class Program5 { public static void main(String[]args)throws FileNotFoundException { //purpose of the program System.out.println("*************************************************************** *"); System.out.println("* This program will read from a data file and *"); System.out.println("* give letter grades to the correct grade ranges, displaying *"); System.out.println("* the min and max grade and caluclate and display average *"); System.out.println("*************************************************************** *"); System.out.println(); S //Table System.out.println("*************************************************************") ; System.out.println("NO. LNAME FNAME GRADES AVG MIN MAX*"); System.out.println("*************************************************************") ; //Declare Variables char letter; String name; String name2; String ss; int a,b,c,d,e,f,Avg,min,max; int A=0, B=0, C=0, D=0, F=0; int G1,G2,G3,G4,G5,G6; i //data file scanner Scanner inFile= new Scanner(new FileReader("h:\\ath.txt")); //loop for(int i=1;i<21;i++) { // data info name = inFile.next(); name2 = inFile.next(); a = inFile.nextInt(); b = inFile.nextInt();
Background image of page 1

Info iconThis preview has intentionally blurred sections. Sign up to view the full version.

View Full Document Right Arrow Icon
c = inFile.nextInt(); d = inFile.nextInt(); e = inFile.nextInt(); f = inFile.nextInt(); //formula
Background image of page 2
Image of page 3
This is the end of the preview. Sign up to access the rest of the document.

{[ snackBarMessage ]}