Tuesday, November 4, 2014

Advanced Regular Expression Features

If you want to employ all regular expressions constructs and features you can't make it with a simple shell command or a tool, but you need to use a programming language. I use Perl, because it has the best and longest established support for regular expression.

Parenthesized Subexpressions

Earlier, we saw that regex engines support metacharacters \1, \2, \3, etc. to refer to the text matched by parenthesized subexpressions. Perl and most other modern regex-endowed languages also provide a way to refer to the text matched by parenthesized subexpressions from code outside of the regular expression, after a match has been successfully completed.

Saturday, November 1, 2014

Introduction to Perl

This guide introduces the Perl language through a number of sample programs. The aim of this guide is to understand how to use regular expressions with Perl.

1 - What is Perl Language

Perl is a scripting language suitable for web-processing. Perl was developed deriving its concepts of text handling and regular expression from two specialized languages called awk and sed.