Strings in functions


I dont know what I have done wrong. Please help

Here is the error message
File "python", line 4
SyntaxError: 'return' outside function

Here is my code
n = "Hello"
# Your function here!
return string_function("world")

print string_function(n)


you need define function called "string_function"
function is defined by
def my_function():

check again chapter about function :wink:


hey,this my code.
n = "Hello"

Your function here!

def string_function(s):
return s + 'world!' #you just need to return the argument,not the function.

print string_function(n)


Thank You. I finally made it work