Find prime numbers Edit
Match HTML (or XML) Tags Edit
This is the most common pattern cited, published by Friedl.
This pattern has two flaws:
- a white space character following the opening angle bracket is not actually a valid tag
- this pattern can be totally catastrophic in the rare case of unbalanced quotation marks occurring inside a tag.
For this reason I prefer the following: