Concept Flow - String Reversal Approaches
Start with original string
Choose reversal method
Method 1: Two-pointer swap
Swap characters from ends moving inward
Complete when pointers meet or cross
Method 2: Build new reversed string
Iterate from end to start
Append characters to new string
Return new reversed string
Output reversed string
End
The flow starts with the original string, then chooses a reversal method: either swapping characters in place using two pointers or building a new reversed string by iterating from the end. Finally, the reversed string is output.
