Difference: RegularExpression (10 vs. 11)

Revision 112016-02-23 - TWikiContributor

Line: 1 to 1
 

Regular Expressions

Line: 7 to 7
  Regular expressions (REs), unlike simple queries, allow you to search for text which matches a particular pattern.
Changed:
<
<
REs are similar to (but more poweful than) the "wildcards" used in the command-line interfaces found in operating systems such as Unix and MS-DOS. REs are used by sophisticated search engines, as well as by many Unix-based languages and tools ( e.g., awk, grep, lex, perl, and sed ).
>
>
REs are similar to (but more powerful than) the "wildcards" used in the command-line interfaces found in operating systems such as Unix and MS-DOS. REs are used by sophisticated search engines, as well as by many Unix-based languages and tools ( e.g., awk, grep, lex, perl, and sed ).
 

Examples

Changed:
<
<
compan(y|ies) Search for company, companies
(peter|paul) Search for peter, paul
>
>
compan(y|ies) Search for company, companies
(peter|paul) Search for peter, paul
 
bug* Search for bug, bugg, buggg or simply bu (a star matches zero or more instances of the previous character)
bug.* Search for bug, bugs, bugfix (a dot-star matches zero or more instances of any character)
[Bb]ag Search for Bag, bag
 
This site is powered by the TWiki collaboration platform Powered by PerlCopyright © 1999-2020 by the contributing authors. All material on this collaboration platform is the property of the contributing authors. <br /> Ideas, requests, problems regarding lt;nopgt;TWiki? lt;a href='mailto:twiki-admin@kcl.ac.uk?subject=TWiki%20Feedback%20on%20TWiki.RegularExpression'gt;Send feedbacklt;/agt; <br /> Note: Please contribute updates to this topic on TWiki.org at <a href="http://twiki.org/cgi-bin/view/TWiki/RegularExpression" target="twiki.org">TWiki:TWiki.RegularExpression</a>.