Function Junction: error at output


#1

I'm stuck at Function Junction code that asks to print string "Eggs!"

I tried defining all the header and body, but still unable to get output to print "Eggs!"

Please help

# Define your spam function starting on line 5. You
# can leave the code on line 11 alone for now--we'll
# explain it soon!

def spam(s):
     """prints string Eggs!"""
     s = "Eggs!"
     print s
     return s
   


# Define the spam function above this line.

error message: Oops, try again. Make sure your function prints "Eggs!" to the console!

`


#2

I don't think you are in need of getting the output twice. Try just returning Eggs! once and take out the print.


#3

Thank you, I get my mistake now..:slight_smile:


#4

You are welcome :grinning:


#5

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