Anonymous Monk has asked for the wisdom of the Perl Monks concerning the following question:
The output of this code is:my $line = 1 | 0.116 0.088 0.173 0.624; @prob = $line =~ m/(\b0\.[0-9][0-9][0-9])/g; print $prob[0], "\n"; print $prob[1], "\n"; print $prob[2], "\n";
($prob[3] is undefined) Why is 0.116 not being found?0.088 0.0173 0.624
Fixed square brackets - dvergin 2003-04-21
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re: regex with multiple matches, missing first match?
by robartes (Priest) on Apr 22, 2003 at 06:34 UTC | |
|
Re: regex with multiple matches, missing first match?
by nite_man (Deacon) on Apr 22, 2003 at 06:34 UTC | |
|
Re: regex with multiple matches, missing first match?
by agentv (Friar) on Apr 22, 2003 at 12:35 UTC |