Ad
Code
Diff
  • getGrade=(a,b,c,m=(a+b+c)/3)=>"FDCBA"[(m>59)+(m>69)+(m>79)+(m>89)]
    • getGrade=(a,b,c,avg=(a+b+c)/3)=>["F","D","C","B","A"][(avg>=60)+(avg>=70)+(avg>=80)+(avg>=90)]
    • getGrade=(a,b,c,m=(a+b+c)/3)=>"FDCBA"[(m>59)+(m>69)+(m>79)+(m>89)]