That not only exludes dot and dot-dot, but anything beginning with dot and dot-dot. Maybe it was intended to exclude ".random.pm", perhaps?my @files = grep !/^\.\.?/ && /.*pm$/, readdir DIRH;
But yes. On a code review, I'd mark that line as "either do what you mean, or write what you mean as a comment".
-- Randal L. Schwartz, Perl hacker
In reply to Re: Re: Directory Listing
by merlyn
in thread Directory Listing
by agoth
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |