use warnings; use strict; use File::Find; my ($recent,$nom,$rep); my $line; $rep = 'D:\\'; sub plus_recent { return unless -f; return if defined $recent and $recent > (stat($_))[9]; $recent = (stat(_))[9]; $nom = $File::Find::name; } find(\&plus_recent,$rep); print $nom; #open (LOG,"; close(LOG); foreach $line (@LogFilePosition) { if ($line =~ /CHAINERECHERCHEE/) { print "C'est démarré !!"; } }