Grading java program with policies
<p>The grading policies are </p>

<p>2 quizzes 10 points</p>

<p>1 midterm exam and one final exam, each graded on the basis of 100 points</p>

<p>the final exam counts for 50% of the grade, the midterm counts for 25%, and the 2 quizzes together count for a total of 25%. </p>

<p>a letter grade is also suppose to be given </p>

<p>this was given by the instructor</p>

<pre><code>import java.util.*;
import java.io.*;

public class Assign7{
  public static void main(String[] args)throws Exception{



    Scanner myIn = new Scanner( new File("scores.txt") );



    System.out.println( myIn.nextLine() +"  avg  "+"letter");

    while( myIn.hasNext() ){
       name = myIn.Next();
       q1 = myIn.nextInt();
       q2 = myIn.nextInt();
       m = myIn.nextInt();
       f = myIn.nextInt();
       Record myR = new Record( name, q1,q2,m,f);
       System.out.println(myR);

    } 
  }
}
</code></pre>

<p>and this is what i came up with so far however i keep getting three error messages </p>

<p>Assign7.java:28; errror: illegal start of expression 
public String toString(){</p>

<p>Assign7.java:28; errror: ';' expected
public String toString(){</p>

<p>Assign7.java:33: error: reached end of file while parsing
}</p>

<p>Could anybody tell me how to fix this errors please (this is my code)</p>

<pre><code>class Assign7{
  private double finalScore;
  private double private_quiz1;
  private double private_quiz2;
  private double private_midTerm;
  private double private_final;
  private final char grade;


  public Assign7(double finalScore){
    private_quiz1 = 1.25;
    private_quiz2 = 1.25;
    private_midTerm = 0.25;
    private_final = 0.50;

        if (finalScore &gt;= 90) {
            grade = 'A';
        } else if (finalScore &gt;= 80) {
            grade = 'B';
        } else if (finalScore &gt;= 70) {
            grade = 'C';
        } else if (finalScore&gt;= 60) {
            grade = 'D';
        } else {
            grade = 'F';


  public String toString(){
    return finalScore+":"+private_quiz1+":"+private_quiz2+":"+private_midTerm+":"+private_final;

  }
} 
</code></pre>
