in reply to Re: global regex
in thread global regex
use strict; use warnings; my $match=0; while(<DATA>){ while(my $text = /Name: *(\w+)/g){ ++$match; print "Match no. $match is $1\n"; } } __DATA__ Name: Alpha Name: Beta Name: Gamma Name: Epsilon Name: Delta
|
---|