Not exactly a regular expression approach. Regexp::Common can be used for these.
use strict; use warnings; use Regexp::Common; my $string = ' =begin a bc d =end '; print $1 if $string=~/$RE{balanced}{-begin => "=begin"}{-end => "end"} +{-keep}/;
Regards,
Murugesan Kandasamy
use perl for(;;);
In reply to Re: Regular expression...
by murugu
in thread Regular expression...
by Anonymous Monk
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |