% Grade Calculator Script


HW = [15 14 18 18 18 18]; %put your scores in here!
MT1 = 70; %midterm scores
MT2 = 90; %midterm scores

Final = 180; %put what you think you will get on the final here
             %note: for percentage divide by 200
Par = 9; %participation score out of possible 10

MT_max = max([MT1,MT2]);%takes max of Midterms 1 and 2 for scheme 2
             
             
HWs = sort(HW); %sort hw
HWa = mean(HWs(3:6)); %drop lowest 2 HW and find average

Grade_s1 = (Par/10)*.05 + (HWa/20)*(.15) + (MT1/100)*0.2 + (MT2/100)*0.2 + (Final/200)*0.4


Grade_s2 = (Par/10)*.05 + (HWa/20)*(.15) + (MT_max/100)*0.2  + (Final/200)*0.6


Final_grade = max(Grade_s1,Grade_s2) 
