Grade Report
JavaScript
20 pts
Grade Report
Write two functions for the school club:
grade(score)returns"A"for 90 or more,"B"for 75 or more,"C"for 50 or more, and"F"below 50.report(name, score)returns a line likeRuta: 95 points, grade A. It must callgrade()to get the letter.
The starter already prints three reports. When your functions work, the output is:
Ruta: 95 points, grade A Yonas: 78 points, grade B Senait: 42 points, grade F
Checklist
- Write
grade(score)that returns the right letter for every score. - Write
report(name, score)that returns the report line and usesgrade(). - The three report lines are printed.
🔑 Solution
If you view the solution before passing, you earn half points for this exercise. You still need to type it and press Check to finish.
How it works, step by step
Point at a step to highlight its lines. Type the solution yourself and press Check answer to finish.
