def reverse(string):
return string[::-1]
s=input(“Enter the string:”)
print(“Reverse of the string:” ,reverse(s))
OUTPUT

LEARN & WIN !!!
def reverse(string):
return string[::-1]
s=input(“Enter the string:”)
print(“Reverse of the string:” ,reverse(s))
OUTPUT

Leave a comment