in reply to How to verify a type of file exists in a directory?

If you are dealing with one directory and not descending into subdirectories, you can use a glob. If you get files back from the glob, then you know they exist.

my @files = glob( "*.fa *.log" );

Note: In this example the current directory has to be the output directory, but you could also use paths in the glob.

--
brian d foy <brian@stonehenge.com>
Subscribe to The Perl Review