public String calculateGrade() {
        double totalMarks = (quiz1 + quiz2 + quiz3 + quiz4) * .10;
        totalMarks += (midTerm1) * .20;
        totalMarks += (midTerm2) * .15;
        totalMarks += finalTerm * .25;

        double percentage = totalMarks; //because total maximum marks are 100 hence totalMarks would be equal to the percentage
        if(percentage >= 90) {
            grade = "A";
        } else if(percentage >=80 && percentage <= 89) {
            grade = "B";
        } else if(percentage >=70 && percentage <= 79) {
            grade = "C";
        } else if(percentage >=60 && percentage <= 69) {
            grade = "D";
        } else {
            grade = "F";
        }

        return grade;

    }