in reply to only list recent files

Use the -M file test on the files.
opendir DIR, $path or die "can't open $path: $!"; while (defined(my $f = readdir DIR)) { push @ok, [ "$path/$f", -M _ ] if (24 * -M "$path/$f") <= 2; } closedir DIR;
Now you can sort on the second element of the array references. The reason I multiply the return value of the modification time is because it returns the time in days. So I turn that into hours.

Just so you know, you can never know when a file on a Unix system was created. It's just not supported.

japhy -- Perl and Regex Hacker