Content deleted Content added
m space |
m categ |
||
Line 1:
A [[regular expression]] ( also "
Despite this variability, and because regular expressions can be difficult to both explain and understand without examples, this article provides a basic description of some of the properties of regular expressions by way of illustration.
== Examples ==
Unless otherwise indicated, the following examples conform to the [[Perl]] programming language, release 5.8.8, [[January 31]] [[2006]]. The examples may also be modified to work in other environments as well, depending on the similarity of syntax rules.
<table class="wikitable">
Line 294 ⟶ 297:
== Notes ==
The character 'm' in the above regular expressions, for example m/[^abc]/, is not required in order for perl to recognize the expression as a 'match' (cf. 'substitute': s/a/b/); /[^abc]/ could just as easily be used without the preceding 'm'. The 'm' operator can be used to alter the delimiting character; for example, m{/} may be used to enhance the legibility of patterns such as /\//. See '[http://perldoc.perl.org/perlre.html perldoc perlre]' for more details.
== See also ==
* [[Comparison of programming languages]]
[[Category:Perl]]
[[Category:Pattern matching]]
[[Category:Articles with example code]]
[[Category:Programming language topics]]
|