Sending a Letter


#1

Dont Know why it is showing a error:
Make sure you defined get_letter_grade

def get_letter_grade(score):
if score >= 90.0:
return "A"
elif score >= 80.0:
return "B"
elif score >= 70.0:
return "C"
elif score >= 60.0:
return "D"
else:
return "F"

        print get_letter_grade(get_average(lloyd))

#2

This part of your code looks okay..
Make sure that you indented it properly.

def get_letter_grade(score):
    if condition:
        return "A"
    elif condition:
        return "B"
    elif condition:
        return "C"
    elif condition:
        return "D"
    else:
        return "F"

Make sure that header of your function is on 0-indentation.

also..Indent it properly
print get_letter_grade(get_average(lloyd))


#3

This topic was automatically closed 7 days after the last reply. New replies are no longer allowed.