>> English << | česky | Deutsch | Español ZVON > Tutorials > Regular Expressions Tutorial
>> Example 26 << | Prev | Next | Contents | Regular Expressions

Description


(?!<pattern>) will look ahead if the pattern exists. If it does there will be no hit.

Source


AAAX---AAA

Case 1


Regular Expression: AAA(?!X)
First match:AAAX---AAA
All matches:AAAX---AAA

Case 2


Regular Expression: AAA
First match:AAAX---AAA
All matches:AAAX---AAA