immutable-string-list-copy-for-swap

Status: IN

Python string immutability forces solutions that swap characters (e.g., `reverseVowels`) to convert to `list(s)`, perform O(1) swaps, then `"".join()` back — avoiding O(n^2) string concatenation.

Source: entries/2026/06/06/reverse-vowels-of-a-string-solution.md

JSON