Perl Monk, Perl Meditation | |
PerlMonks |
Re: Can I change the definition of '\s'?by mephit (Scribe) |
on Sep 11, 2002 at 20:38 UTC ( [id://197070]=note: print w/replies, xml ) | Need Help?? |
As perlman:perlfaq4 says, is would be better to remove leading and trailing whitespace with two steps, not one:
So, I'd suggest doing it with two separate supstitutions and the custom-character-class-as-a-string that davorg and John M. Dlugosz suggested. HTH -- There are 10 kinds of people -- those that understand binary, and those that don't.
In Section
Seekers of Perl Wisdom
|
|