Q:

Debugging my letter grade calculator in Java

I am supposed to create a program to do the following:

A student must take two quizzes and two exams during the semester.  One quiz and one exam are dropped from the calculation of their final grade.  The remaining quiz counts as 40% of the final grade and the exam counts for 60% of their final grade.
The final grade is calculated on a straight scale: 90% and above is an “A”, less than 90% to 80% is a B, etc.
This program should allow a professor to enter a student’s name, id number, two quiz scores and two exam scores and then compute and output the student’s final grade.

Below is the code I have written. It executes just fine, without any errors, and I feel like I have completed everything correctly; however, the program returns the letter grade "A" no matter what scores I put in.
public static void main(String[] args)
{
    //Declare all variables
    String name;
    String idNum;
    int q1;
    int q2;
    int e1;
    int e2;
    int bestQuiz;
    int bestExam;
    double score;
    char letterGrade;
    
    Scanner kbd;
    kbd = new Scanner(System.in);
    
    System.out.println("Enter student's name: ");
    name = kbd.nextLine();
    System.out.println("Enter student's ID number: ");
    idNum = kbd.nextLine();
    System.out.println("Enter the quiz scores: ");
    q1 = kbd.nextInt();
    q2 = kbd.nextInt();
    System.out.println("Enter the exam scores: ");
    e1 = kbd.nextInt();
    e2 = kbd.nextInt();
    
    bestQuiz = max(q1, q2);
    bestExam = max(e1, e2);
    
    score = computeRawPercentage(bestQuiz, bestExam);
    
    letterGrade = finalGrade( score );
    
    System.out.print(name + " " + idNum + " ");
    System.out.println("Final Grade: " + letterGrade);
    
}
    
    //Max method
   public static int max(int n1, int n2){
        int big;
        if (n1 > n2){
            big = n1;
        }
        else {
            big = n2;
        }
        return big;
    }
   
   //computeRawPercentage method
   public static double computeRawPercentage(int quizScore, int examScore){
       return ((quizScore * .4)+ (examScore * .6))*100;
   }
   
   //finalGrade method
   public static char finalGrade(double grade){
       
       char letterGrade;
       
       if (grade >= 90.0)
           letterGrade = 'A';
       else if ((grade >= 80.0)&&(grade < 90.0))
           letterGrade = 'B';
       else if ((grade >= 70.0)&&(grade < 80.0))
           letterGrade = 'C';
       else if ((grade >= 60.0)&&(grade < 70.0))
           letterGrade = 'D';
       else
           letterGrade = 'F';
       
       return letterGrade;
       
   }
           
   
   
   
   }

A:

Your problem is this line:
return ((quizScore * .4)+ (examScore * .6))*100;

Here you are are multiplying your score by 100 which will give you a score of something like 7100 when it should be 71 (which is clearly above 90.0).  Delete the 100 multiply and it will work:
return ((quizScore * .4) + (examScore * .6));

Test Run:
Enter student's name: 
TestName
Enter student's ID number: 
12345
Enter the quiz scores: 
55
65
Enter the exam scores: 
65
86
77.6
TestName 12345 Final Grade: C

This is assuming you enter a score of 75% as 75.

