Error: Did you create a function?


#1



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

Error: Oops, try again. Did you create a function called shut_down?


def shut_down(s): 
    if s=="yes":
        return "Shutting down"
    elif shut=="no":
        return "Shutdown aborted"
    else:
        return "Sorry"

s=="yes"


#2

your last line:

s=="yes"

i don't understand the purpose it serves, i would remove it.

in your elif condition, you compare shut with "no", instead of comparing s with "no", causing the error message.


#3

Ooops..that was a typo.

the code worked now.

Thanks for your help!


#4