擅长:python、mysql、java
<p>你的正则表达式说“我想匹配一个辅音;它后面应该跟一个元音”。但是你的要求是“我想匹配一个元音;它前面应该有一个辅音”</p>
<p>更准确地说,您希望从前向断言<code>(?=...)</code>切换到后向断言<code>(?<=...)</code>,并可能理解前后向断言的含义。查找添加了一个条件,但与满足该条件的文本不匹配(或“使用”)。所以</p>
<pre><code>(?<=[b-df-hj-np-tv-xz])[aeiouy]
</code></pre>
<p>匹配元音,但前提是前一个字符满足lookback</p>