Hello I am at Exercise 6 in List and Functions and I get an really odd error-message:
Oops, try again. string_function('Waynes') returned 'Helloworld' instead of 'Waynesworld'

If I change the function into "Waynesworls" it gives the Error:
Oops, try again. string_function('Hello') returned 'Waynesworld' instead of 'Helloworld'

Thanks for any support!

Replace this line with your code. 
n = "Hello"
# Your function here!

def string_function(n):
    return n + "world"

print string_function(n)


Your code is perfect. I copy pasted it in my editor and I passed the lesson. Just check what happens if you don't print it (just delete the last line). Because, codecademy maybe trying to pass some other argument into your function. As you told that:

This is of no wonder. You passed "Wayne" while codecademy tried to pass "Hello". That's it.
So, just try deleting that call on your function. :smile:


Thank you! Now everything works just fine!


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