Karl wrote: > > Hi all. Hello,
> Is there a module or function which will return the number of files in a dir > or at least have similar results as > > ls -1 | wc -l For the same results as above: my $number_of_files = () = <*>; However that also includes directory names and does not include "hidden" files. # only file names my $number_of_files = grep -f, <*>; # include hidden files my $number_of_files = grep -f, <* .*>; John -- use Perl; program fulfillment -- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] <http://learn.perl.org/> <http://learn.perl.org/first-response>