how to reverse a string in python using slicing code example
Example 1: python reverse string
'String'[::-1] #-> 'gnirtS'
Example 2: reverse string in python
'hello world'[::-1]
'dlrow olleh'
Example 3: python string reverse
'hello world'[::-1]
# 'dlrow olleh'