in reply to
Can a defined value be of zero length?
I guess you could almost rewrite your test:
last unless $pattern;
[download]
except that it would return a different result if the user input is 0 or "0".
Comment on
Re: Can a defined value be of zero length?
Download
Code
In Section
Seekers of Perl Wisdom