Python beginner exercise 3: reverse a string
Also post on Question write a program to reverse a given string str1 = "PYnative" Expected output evitanYP My attempt str1 = "PYnative" reversed_string = str1[::-1] print(reversed_string) Recommend solution str1 = "PYnative" print("Original String is:", str1) str1 = ''.join(reversed(str1))…