擅长:python、mysql、java
<p>正如jornsharpe</em>所建议的那样<code>(?<=[^aeiouy])[aeiouy]</code>是错误的,因为它与例如。
在<strong>空格</strong>或<strong>数字</strong>后的元音</p>
<p>要完成任务,请使用:</p>
<pre><code>(?<=[b-df-hj-np-tv-xz])[aeiouy]
</code></pre>
<p>可能带有<em>re.I</em>(忽略大小写)标志</p>
<p>第一部分(<code>(?<=[b-df-hj-np-tv-xz])</code>)是一个<em>积极的回顾</em>,
检查你的情况“之前有一个元音”。
第二部分(<code>[aeiouy]</code>)只匹配一个辅音</p>
<p>有关<em>环顾四周</em>(<em>向后看</em>和<em>向前看</em>)的说明,请在Web上搜索。
即使在<em>上,你也会找到大量的解释和例子</p>
<p>有关<em>regex101</em>中的示例,请参见<a href="https://regex101.com/r/Ze9hr0/1" rel="nofollow noreferrer">https://regex101.com/r/Ze9hr0/1</a></p>