Hi all,
this could be trivial, and I suspect the answer is that the regexp
engine is smart enough, but suppose I want to test the following:

$extention =~ / \.bat | \.BAT /x;

is the following a better solution?

$extension = lc $extension;
$extension =~ / \.bat /x;

In other words, when testing for all-lower or all-upper cases should I
first trasnform to one of them or use a regexp with alternatives?
Any suggestion?

Thanks,
Luca

-- 
To unsubscribe, e-mail: beginners-unsubscr...@perl.org
For additional commands, e-mail: beginners-h...@perl.org
http://learn.perl.org/


Reply via email to