I'm stuck trying to surround some text found via regex with brackets. For example replacing all is
with (is)
:
Input is : This is a long sentence that IS written.
Desired output: This (is) a long sentence that (IS) written.
How can I do this? (While still maintaining the original case-ness of the found strings)