in reply to Re: Test RegEx
in thread Test RegEx

I, too, got lost and gave up pretty quickly (although I think JavaFan has set the OPer on the right path), but  @- and  @+ are regex-related special variables, so things like  $-[0] and  $+[0] are valid.

Another oddity of the OPer's original code is

my @LINES=<DATA>; my $tLINES=@LINES; foreach $RECORD (@LINES[0..$tLINES-1]) { ... }

This seems to boil down to (assuming you don't just use a  while loop)

my @LINES = <PROPERFILEHANDLE>; foreach $RECORD (@LINES) { ... }