Kodewick
Start learning →
Basic←→0 / 100

Grade it

#009BasicConditions4 min

The report shows a grade: 90 and above is "A", 80 to 89 "B", 60 to 79 "C", below 60 "D". Write grade(score) to return it.

Examples
grade(95)→'A'
grade(82)→'B'
grade(61)→'C'
main.py
def grade(score):
    if score >= 90:
        return "A"
    # your code here: then B and C; anything left is D
    pass
Ctrl + Enter runs too
Result

Run tries the examples. When they look right, Submit.