Charles and Jenda, thanks for your responses. In addition to the change that
you both suggested, I had a problem with the array variable @directory in my
exists test. I was testing the entire array instead of just the current
cell. Charles, thanks for your suggestion on opendir, I will look into it.
Terry Poperszky
chomp (@directory = `dir /b /O-D`);
open MYFILE, "<dir_log" or die "Log File Missing";
while (<MYFILE>) {
chomp (); $dir_log{$_} = 1;
}
foreach (@directory) {
print $_ if (exists $dir_log{$_});
}