Hi everyone! When I run this code it reverses the string when using print to check it, but when i change print to return, Codecademy claims that the code is not returning the reversed string. Codecademy claims the code is only returning the first character of the reversed string, in this case "!". Even though I see that it works before.
Any ideas on what is causing the problem, I really don't see where I could go from here.
Thanks in advance!
def reverse(text): i = len(text) while i > 0: return text[i-1] i -= 1 reverse("Python!")