A function that takes a string text and returns that string in reverse.
@pole55 your reverse function could be changed to:
as [::-1] basically tells Python to return a string that is stepped over every 1 letter (which does nothing), but backwards, which reverses the string.
@ash15khng, you're right! this is a great option, but I'm only learning the language and trying out different solutions. not only simple and obvious
@pole55 Oh, I was just suggesting another shorter variation to your code, which in most cases is preferable. However your method is more logical so it also works.