in reply to Re: regular expression to match specific members of a bus_name
in thread regular expression to match specific members of a bus_name

Thanks! Despite the murkiness of my question, you provided the magic I was looking for:

 my $match_str="[tr]x_n1(?!\\d)";

It was the zero-width negative look-ahead assertion  (?!\d) that I was looking for

BTW your use of map is spinning my head :) I will also be looking into qr

Replies are listed 'Best First'.
Re^3: regular expression to match specific members of a bus_name
by AnomalousMonk (Archbishop) on Feb 12, 2016 at 17:53 UTC

    qr// is definitely worth knowing about and using in regex composition. And map/grep are quite useful too.


    Give a man a fish:  <%-{-{-{-<