We are given a string. We are also given indexes of first and last characters in string. The task is to reverse the string without using any extra variable.
Examples:
Input : str = "abc"
Output : str = "cba"
Input : str = "GeeksforGeeks"
Output : str = "skeeGrofskeeG"
Reverse string without using any temporary variable: https://www.geeksforgeeks.org/reverse-string-without-using-any-temporary-variable/