Regex pattern to handle both case-sensitive and case-insensitive in a single statement
<p>I have a small regex to handle. I have 2 different terms. </p>

<ol>
<li>"United States", which I would like to match ignoring the case</li>
<li>"US", which I would like to match <em>without</em> ignoring case.</li>
</ol>

<p>I want to do the following two regex substitution in a single regex substitute statement.</p>

<pre><code>clntxt = re.sub('(?i)United States', 'USA', "united states")
# Output: USA
clntxt = re.sub('US', 'USA', "US and us")
# output: USA and us
</code></pre>

<p>I need something like </p>

<pre><code>clntxt = re.sub('(?i)United States|(?s)US', 'USA', "united states and US and us")
# output: USA and USA and us
</code></pre>

<p>How can I achieve the above?</p>