An Introduction to Regular Expressions What Are Regexes? 3 of 50 : [PREV] [NEXT]

What Are Regexes?

Regular Expressions are a set of special set search strings, which can contain powerful metacharacters to pattern match against a set of strings.

Many tasks can be done with regular expressions.

You can:

  • find out whether a given string matches a particular pattern.
  • find out where the matching substring is located within the string.
  • use a substitution command to replace matching sections with another string
  • use the split() operator to return an array of all substrings your pattern did not match.

© 2003 Barbie barbie@missbarbell.co.uk Home http://birmingham.pm.org/