Sending a letter


#1



https://www.codecademy.com/courses/python-beginner-en-qzsCL/1/3?curriculum_id=4f89dab3d788890003000096#


Error- get_letter_grade seems to be missing.


  def get_letter_grade(score):
        if score>=90:
            return "A"
        elif score>=80:
            return "B"
        elif score>=70:
            return "C"
        elif score>=60:
            return "D"
        else:
            return "F"
        
    print get_letter_grade(get_average(lloyd))


#2

It seems like you have two indents before your if- statements.
Now your code looks like this:

def get_letter_grade(score):
           if score>=90:

You should just remove the extra indents.

def get_letter_grade(score):
     if score>=90:

#3

why does your function have indent? can we see your full code?


#4


The indentation is just a copy error, This is my full code


#5

no, it is not a copy error, it is as i expected.

the get_letter_grade function should be after the get_average, not nested inside the get_average function


#6

OH, Didn't even notice, Thank you very much :slight_smile:


#7

Oops, I didn't see that, too. Thanks stetim


#8

@shelo16, issue resolved?

@papusalaatti, we are human we all sometimes miss things (myself obviously included :stuck_out_tongue: )


#9

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