|
|
| Perl: the Markov chain saw | |
| PerlMonks |
Re: change [A-Z] to U, [a-z] to L with one regex?by rjt (Friar) |
| on Mar 19, 2013 at 23:05 UTC ( #1024399=note: print w/ replies, xml ) | Need Help?? |
|
You can always use $_:
Yes, this is technically still two expressions, but as others have stated, it'll be efficient, and to me, anyway, the comma operator has good semantic meaning, here, even though a semicolon would do just as well. Update: Corrected bracket typo in y///. Thanks jwkrahn.
In Section
Seekers of Perl Wisdom
|
|
||||||||||||||||||||||