Beefy Boxes and Bandwidth Generously Provided by pair Networks
Keep It Simple, Stupid
 
PerlMonks  

Re: Answer: How do I read all the file names of a directory into an array?

by chipmunk (Parson)
on Dec 12, 2000 at 02:06 UTC ( [id://46153]=note: print w/replies, xml ) Need Help??


in reply to Re: How do I read all the file names of a directory into an array?
in thread How do I read all the file names of a directory into an array?

A tip about grep and map: using two in a row is almost always unnecessary. For example, the grep {} grep {} in the above code can be made into a single grep {} with the and operator.
map { qq{<a href="$_">$_</a><br>} } ## format each file sort ## sort them grep { !/^\./ and -T "$dir$_" } ## no .name files, text fil +es only readdir MYDIR

Log In?
Username:
Password:

What's my password?
Create A New User
Domain Nodelet?
Node Status?
node history
Node Type: note [id://46153]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this?Last hourOther CB clients
Other Users?
Others perusing the Monastery: (3)
As of 2024-03-28 16:31 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found