in reply to "Str8-forward" RE prob? {w/range}

my $tgt_RE1 = qr{ ([SK]) ([0-9]{1-3}) ([-_\.\w]+) }x;

should be

my $tgt_RE1 = qr{ ([SK]) ([0-9]{1,3}) ([-.\w]+) }x;

The range isn't {1-3}, but {1,3}

Note that underscore, _, is a word and dot doesn't need to be escaped in a character class.

Replies are listed 'Best First'.
Re^2: "Str8-forward" RE prob? {w/range}
by perl-diddler (Chaplain) on Oct 15, 2016 at 01:03 UTC
    Oh, poo! RE: '_' -- I added it to my match string when the {x-y} didn't work (when it should have been ',')... tnx!