Perl: the Markov chain saw | |
PerlMonks |
(Ovid) RE(2): regexp'sby Ovid (Cardinal) |
on Oct 03, 2000 at 18:27 UTC ( [id://35111]=note: print w/replies, xml ) | Need Help?? |
AAAAAAARRRRRRRGGGGGGGGGHHHHHHHHH! I had them backwards!!!! I hate it when I do that!!!
Yes, I'm anal about the .* thing. I'm also anal about use strict, -w, checking that my open actually opened something, etc. I do see your point and I acknowledge that your regex is much simpler to read. However, iteration combined with dot star is begging for issues. In this case, though, since the backtracking appears to be small (just 4 characters, max) -- assuming that this is not just an over-simplified subset of data -- it's probably not that much of an issue.
Cheers, Join the Perlmonks Setiathome Group or just go the the link and check out our stats.
In Section
Seekers of Perl Wisdom
|
|