Help for this page

Select Code to Download


  1. or download this
    c:\@Work\Perl\monks>perl -wMstrict -le
    "my $pattern = qr{ \b f[eio]e \b }xms;
    ...
     print qq{match: '$1'} if $str =~ m{ (bar (?: (?! $pattern) .)* f \w+)
    + }xms;
    "
    match: 'bar feeble macfee unfeeling fee'
    
  2. or download this
    c:\@Work\Perl\monks>perl -wMstrict -le
    "my $giant_sez = qr{ \b f[eio]e \b     }xms;
    ...
     print qq{match: '$1'} if $str =~ m{ (bar $not_giant* f \w+) }xms;
    "
    match: 'bar feeble macfee unfeeling fee'