
Given a string s, return a new string containing the characters of s in reverse order. Solve the problem without using Python's built-in reverse helpers such as slicing with [::-1], reversed(), or converting directly through convenience methods that already perform the reversal.
Example 1:
Input: s = "hello"
Output: "olleh"
Explanation: The characters are returned in reverse order.
Example 2:
Input: s = "a b!"
Output: "!b a"
Explanation: Spaces and punctuation are treated like ordinary characters.
0 <= len(s) <= 10^5s may contain letters, digits, spaces, and punctuations = "hello"Output"olleh"WhyThe first and last characters swap, then the second and fourth swap.s = "a b!"Output"!b a"WhyAll characters, including spaces and punctuation, are reversed by position.0 <= len(s) <= 10^5s may contain letters, digits, spaces, and punctuationDo not use built-in reverse helpers such as slicing with `[::-1]` or `reversed()`def reverse_string(s):