Think about Loose Coupling | |
PerlMonks |
Re: Regex Not Grabbing Everythingby japhy (Canon) |
on Sep 17, 2010 at 14:05 UTC ( [id://860493]=note: print w/replies, xml ) | Need Help?? |
Update: I need to take a closer look at your code.
Could you explain, a bit more abstractly, what it is you are attempting to do? You want the lines which have ' 0.00' at column 118, correct? First, your bracing and indenting style leaves something to be desired. Here's how I'd write your code: You were using == which is for strictly numeric data, but you want to use eq because you're looking specifically for the characters '0.00'. You either want to change your substr() to 4 characters, or else look for ' 0.00', I think. Jeff japhy Pinyan, P.L., P.M., P.O.D, X.S.: Perl, regex, and perl hacker Nos autem praedicamus Christum crucifixum (1 Cor. 1:23) - The Cross Reference (My Blog)
In Section
Seekers of Perl Wisdom
|
|