my $BestTime; my $BestOffBy; my $ctime = (stat($key))[10]; print "IN MULTIPLES \$ctime is $ctime\n"; for (@returns) { print "Working Multiple match: $_\n"; my $temp = abs($ctime - $_); if ($temp < $BestOffBy) { $BestOffBy = $temp; $BestTime = $_ } } print "$BestTime is only $BestOffBy away from $ctime.";