14,953
edits
(→快速查表) |
|||
| Line 85: | Line 85: | ||
<span style="background:#C6E3FF">What Does the shiba inu say? 柴犬怎叫 </span> | <span style="background:#C6E3FF">What Does the shiba inu say? 柴犬怎叫 </span> | ||
</td> | </td> | ||
</tr> | |||
<tr> | |||
<td> 布林邏輯 AND: 包含「狐狸」和「叫」的行 ([http://regexr.com/3aokl demo])<br /> {{kbd | key = <nowiki>(?=.*狐狸)(?=.*叫).*</nowiki>}}</td> | |||
<td> | |||
<span style="background:#C6E3FF">What Does the Fox Say? 12 狐狸怎叫 34</span><br /> | |||
What Does the shiba inu say? 柴犬怎叫 | |||
</td> | |||
<td></td> | |||
<td></td> | |||
</tr> | |||
<tr> | |||
<td> 布林邏輯 OR: 包含「狐狸」或「叫」的行 ([http://regexr.com/3aoko demo])<br /> {{kbd | key = <nowiki>.*(狐狸|叫).*</nowiki>}}</td> | |||
<td> | |||
<span style="background:#C6E3FF">What Does the Fox Say? 12 狐狸怎叫 34<br /> | |||
What Does the shiba inu say? 柴犬怎叫</span> | |||
</td> | |||
<td></td> | |||
<td></td> | |||
</tr> | |||
<tr> | |||
<td> 布林邏輯 NOT: 不包含「狐狸」,但包含「柴犬」的行 ([http://regexr.com/3aokr demo])<br /> {{kbd | key = <nowiki>^((?!狐狸).)*(柴犬).*$</nowiki>}} = {{kbd | key = <nowiki>^(柴犬).*((?!狐狸).)*$</nowiki>}} = {{kbd | key = <nowiki>(柴犬).*((?!狐狸).)*</nowiki>}}<ref>[http://stackoverflow.com/questions/2953039/regular-expression-for-a-string-containing-one-word-but-not-another regex - Regular expression for a string containing one word but not another - Stack Overflow]</ref></td> | |||
<td> | |||
<span style="background:#C6E3FF">What Does the Fox Say? 12 狐狸怎叫 34</span><br /> | |||
What Does the shiba inu say? 柴犬怎叫 | |||
</td> | |||
<td></td> | |||
<td></td> | |||
</tr> | </tr> | ||
</table> | </table> | ||